Oihana PHP Arango

ReplaceOptions extends QueryOptions

Table of Contents

Constants

CACHE_ENABLED  : string = 'cacheEnabled'
DEDUPLICATE  : string = 'deduplicate'
DISABLE_INDEX  : string = 'disableIndex'
ESTIMATES  : string = 'estimates'
EXCLUSIVE  : string = 'exclusive'
EXPIRE_AFTER  : string = 'expireAfter'
FIELD_VALUE_TYPES  : string = 'fieldValueTypes'
FIELDS  : string = 'fields'
FORCE_INDEX_HINT  : string = 'forceIndexHint'
GEO_JSON  : string = 'geoJson'
IGNORE_ERRORS  : string = 'ignoreErrors'
IGNORE_REVS  : string = 'ignoreRevs'
IN_BACKGROUND  : string = 'inBackground'
INDEX_HINT  : string = 'indexHint'
KEEP_NULL  : string = 'keepNull'
LEGACY_POLYGONS  : string = 'legacyPolygons'
LOOKAHEAD  : string = 'lookahead'
MAX_PROJECTIONS  : string = 'maxProjections'
MERGE_OBJECTS  : string = 'mergeObjects'
METHOD  : string = 'method'
NAME  : string = 'name'
OVERWRITE_MODE  : string = 'overwriteMode'
PARALLELISM  : string = 'parallelism'
PARAMS  : string = 'params'
PREFIX_FIELDS  : string = 'prefixFields'
READ_OWN_WRITES  : string = 'readOwnWrites'
REFILL_INDEX_CACHES  : string = 'refillIndexCaches'
SPARSE  : string = 'sparse'
STORED_VALUE  : string = 'storedValue'
TYPE  : string = 'type'
UNIQUE  : string = 'unique'
USE_CACHE  : string = 'useCache'
WAIT_FOR_SYNC  : string = 'waitForSync'

Properties

$exclusive  : bool
The RocksDB engine does not require collection-level locks. Different write operations on the same collection do not block each other, as long as there are no write-write conflicts on the same documents.
$ignoreErrors  : bool
Suppress query errors that may occur when trying to update non-existing documents or when violating unique key constraints.
$ignoreRevs  : bool
In order to not accidentally overwrite documents that have been modified since you last fetched them, you can use the option ignoreRevs to either let ArangoDB compare the _rev value and only succeed if they still match, or let ArangoDB ignore them (default).
$refillIndexCaches  : bool
Whether to update existing entries in in-memory index caches if document updates affect the edge index or cache-enabled persistent indexes.
$versionAttribute  : string|null
You can use the versionAttribute option for external versioning support.
$waitForSync  : bool
To make sure data are durable when an update query returns.

Methods

__construct()  : mixed
Creates a new QueryOptions instance.
jsonSerialize()  : array<string|int, mixed>
Invoked to serialize the object with the json serializer.

Constants

Properties

$exclusive

The RocksDB engine does not require collection-level locks. Different write operations on the same collection do not block each other, as long as there are no write-write conflicts on the same documents.

public bool $exclusive

From an application development perspective it can be desired to have exclusive write access on collections, to simplify the development. Note that writes do not block reads in RocksDB. Exclusive access can also speed up modification queries, because we avoid conflict checks.

Tags
see
https://docs.arangodb.com/stable/aql/high-level-operations/replace/#exclusive

$versionAttribute

You can use the versionAttribute option for external versioning support.

public string|null $versionAttribute

If set, the attribute with the name specified by the option is looked up in the stored document and the attribute value is compared numerically to the value of the versioning attribute in the supplied document that is supposed to update it.

For example, the following query conditionally updates an existing document with the key "123" if the attribute externalVersion currently has a value below 5: UPDATE { _key: "123", externalVersion: 5, anotherAttribute: true } IN coll OPTIONS { versionAttribute: "externalVersion" } You can check if OLD._rev and NEW._rev are different to determine if the document has been changed.

Tags
see
https://docs.arangodb.com/stable/aql/high-level-operations/replace/#versionattribute

Methods

__construct()

Creates a new QueryOptions instance.

public __construct([array<string|int, mixed>|object|null $init = null ]) : mixed
Parameters
$init : array<string|int, mixed>|object|null = null

A generic object containing properties with which to populate the newly instance. If this argument is null, it is ignored.

jsonSerialize()

Invoked to serialize the object with the json serializer.

public jsonSerialize() : array<string|int, mixed>
Tags
throws
ReflectionException
Return values
array<string|int, mixed>
On this page

Search results