en-US/about_Mdbc.help.txt

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
TOPIC
    about_Mdbc
 
SHORT DESCRIPTION
    MongoDB cmdlets based on the official C# driver.
 
LONG DESCRIPTION
    The module provides the following cmdlets and tools:
 
    Connect, set the default server, database, and collection:
 
        Connect-Mdbc
 
    Add, get, remove, and update documents:
 
        Add-MdbcData
        Get-MdbcData
        Remove-MdbcData
        Update-MdbcData
 
    Create new documents, e.g. for Add-MdbcData, Export-MdbcData:
 
        New-MdbcData
 
    Create update expressions, e.g. for Update-MdbcData:
 
        New-MdbcUpdate
 
    Create queries, e.g. for Get-MdbcData, Update-MdbcData:
 
        New-MdbcQuery
 
    Add collections with special properties, e.g. capped:
 
        Add-MdbcCollection
 
    Invoke map and reduce:
 
        Invoke-MdbcMapReduce
 
    Invoke MongoDB commands including not covered by Mdbc or C# driver:
 
        Invoke-MdbcCommand
 
    bson/json data persistence without MongoDB:
 
        Export-MdbcData
        Import-MdbcData
 
    bson/json file collections without MongoDB:
 
        Open-MdbcFile
        Save-MdbcFile
 
    Some more features for interactive sessions:
 
        Mdbc.ps1
 
FILE COLLECTIONS
    Mdbc introduces bson/json file collections which do not require MongoDB.
    They are opened and saved by Open-MdbcFile and Save-MdbcFile and support
    commands Get-MdbcData, Add-MdbcData, Remove-MdbcData, and Update-MdbcData.
 
    Not supported with file collections
 
        * Command Invoke-MdbcAggregate
        * Command Invoke-MdbcMapReduce
        * $where queries
 
    Not supported with simple data (no _id)
 
        * Parameter Update in Add-MdbcData
 
    About invalid element names *.*, $*
 
        File collections read documents from files without name checks. This is
        not an issue for files created and maintained by Open|Save-MdbcData and
        Add|Remove|Update-MdbcData, all names should be valid. Files created
        differently, e.g. by Export-MdbcData, may have invalid element names.
 
    Error and write concern processing
 
        Exceptions thrown on data updates are caught by cmdlets and converted
        to not terminating errors. MongoDB and file collection error message
        texts are different but they should normally explain the same causes.
 
        For file collections write concern is always acknowledged, parameters
        WriteConcern are ignored in all cmdlets. All issues result in errors.
 
    Result of Add-MdbcData, Remove-MdbcData, Update-MdbcData
 
        The switch Result tells to output a WriteConcernResult object.
        Its properties with remarks for file collections are:
 
            HasLastErrorMessage : used as usual
            DocumentsAffected : used as usual
            UpdatedExisting : used as usual
            Ok : used as usual
 
            LastErrorMessage : text is different to MongoDB
            ErrorMessage : text is different to MongoDB
            Response : may be different to MongoDB response
 
            Code : not used
            Command : not used
            CommandName : not used
 
        Used as usual values are normally the same as with MongoDB but
        differences are still possible, especially on various errors.
 
SEE ALSO
    MongoDB http://www.mongodb.org
    C# driver https://github.com/mongodb/mongo-csharp-driver