1MONGOC_COLLECTION_FIND_AND_MODIFYM_OWNIlGTiOHbC_m_OoCPnOTgLSoL(cE3C)TION_FIND_AND_MODIFY_WITH_OPTS(3)
2
3
4

SYNOPSIS

6          bool
7          mongoc_collection_find_and_modify_with_opts (
8             mongoc_collection_t *collection,
9             const bson_t *query,
10             const mongoc_find_and_modify_opts_t *opts,
11             bson_t *reply,
12             bson_error_t *error);
13

PARAMETERS

15collection: A mongoc_collection_t.
16
17query: A bson_t containing the query to locate target document(s).
18
19opts: A find and modify options. Must not be NULL.
20
21reply:  An  optional  location  for a bson_t that will be initialized
22         with the result or NULL.
23
24error: An optional location for a bson_error_t or NULL.
25

DESCRIPTION

27       Update and return an object.
28
29       reply is always initialized, and must be freed with bson_destroy().
30
31       If    an    unacknowledged    write    concern    is    set    (through
32       mongoc_find_and_modify_opts_append()),  the  output  reply is always an
33       empty document.
34
35       On success, the output reply contains the full server reply to the fin‐
36       dAndModify  command.  See the MongoDB Manual page for findAndModify for
37       the expected server reply.
38

ERRORS

40       Errors are propagated via the error parameter.
41

RETURNS

43       Returns true if successful. Returns false and sets error if  there  are
44       invalid arguments or a server or network error.
45
46       A write concern timeout or write concern error is considered a failure.
47

EXAMPLE

49       See the example code for mongoc_find_and_modify_opts_t.
50

AUTHOR

52       MongoDB, Inc
53
55       2017-present, MongoDB, Inc
56
57
58
59
601.25.1                          MNOoNvGO0C8_,CO2L0L2E3CTION_FIND_AND_MODIFY_WITH_OPTS(3)
Impressum