apiargs-MongoDBCollection-method-findOneAndUpdate-option.yaml 1.65 KB
Newer Older
1 2 3 4 5 6 7
source:
  file: apiargs-MongoDBCollection-method-find-option.yaml
  ref: projection
---
source:
  file: apiargs-MongoDBCollection-method-find-option.yaml
  ref: sort
8
---
9 10 11
source:
  file: apiargs-MongoDBCollection-common-option.yaml
  ref: arrayFilters
12 13
post: |
  .. versionadded:: 1.3
14
---
15 16 17
source:
  file: apiargs-MongoDBCollection-common-option.yaml
  ref: collation
18
---
19 20 21 22 23 24 25 26 27
source:
  file: apiargs-common-option.yaml
  ref: hint
post: |
  This option is available in MongoDB 4.4+ and will result in an exception at
  execution time if specified for an older server version.

  .. versionadded:: 1.7
---
28 29 30 31 32
source:
  file: apiargs-common-option.yaml
  ref: maxTimeMS
---
source:
33
  file: apiargs-MongoDBCollection-common-option.yaml
34 35 36 37 38 39
  ref: bypassDocumentValidation
---
arg_name: option
name: returnDocument
type: integer
description: |
40
  Specifies whether to return the document before the update is applied, or
41
  after. ``returnDocument`` supports the following values:
42 43 44

  - ``MongoDB\Operation\FindOneAndUpdate::RETURN_DOCUMENT_BEFORE`` (*default*)
  - ``MongoDB\Operation\FindOneAndUpdate::RETURN_DOCUMENT_AFTER``
45
interface: phpmethod
46
operation: ~
47
optional: true
48
---
49 50 51
source:
  file: apiargs-common-option.yaml
  ref: session
52 53
post: |
  .. versionadded:: 1.3
54
---
55 56 57 58 59 60
source:
  file: apiargs-MongoDBCollection-common-option.yaml
  ref: typeMap
post: |
  This will be used for the returned result document.
---
61
source:
62
  file: apiargs-MongoDBCollection-common-option.yaml
63 64 65
  ref: upsert
---
source:
66
  file: apiargs-MongoDBCollection-common-option.yaml
67
  ref: writeConcern
68
post: |
69 70
  This is not supported for server versions prior to 3.2 and will result in an
  exception at execution time if used.
71
...