Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 35 additions & 29 deletions source/reference/command/updateZoneKeyRange.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,61 +46,67 @@ Definition
.. list-table::
:header-rows: 1
:widths: 20 20 80

* - Parameter

- Type

- Description

* - ``updateZoneKeyRange``

- string

- The namespace of the collection to associate with the range.

The collection must be sharded for the command to succeed.



* - ``min``

- document

- The inclusive lower bound of the range of :term:`shard key` values.

Specify each field of the shard key in the form of ``<fieldname> : <value>``.
The value must be of the same BSON type or types as the shard key.




.. note::

To use hashed sharding, the field value needs to be of type
:bsontype:`NumberLong <data_numberlong>`.

* - ``max``

- document

- The exclusive upper bound of the range of :term:`shard key` values.

Specify each field of the shard key in the form of ``<fieldname> : <value>``.
The value must be of the same BSON type or types as the shard key.




.. note::

To use hashed sharding, the field value needs to be of type
:bsontype:`NumberLong <data_numberlong>`.

* - ``zone``

- string

- The name of the zone to associate with the range bounded by the
``min`` and ``max``.

If the value does not match an existing zone, the command fails.

Specify ``null`` to remove the association between the range with lower
bounds of ``min`` and upper bound of ``max`` and the ``updateZoneKeyRange``
collection. The values of ``min`` and ``max`` must match exactly the target
range.





If no zone range matches the minimum and maximum bounds passed to
Expand Down
60 changes: 33 additions & 27 deletions source/reference/method/sh.updateZoneKeyRange.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,54 +27,60 @@ Definition
.. list-table::
:header-rows: 1
:widths: 20 20 80

* - Parameter

- Type

- Description

* - ``namespace``

- string

- The :term:`namespace` of the sharded collection associate with the ``zone``.

The collection must be sharded for the operation to succeed.



* - ``minimum``

- document

- The inclusive lower bound of the range of :term:`shard key` values.

Specify each field of the shard key in the form of ``<fieldname> : <value>``.
The value must be of the same BSON type or types as the shard key.




.. note::

To use hashed sharding, the field value needs to be of type
:bsontype:`NumberLong <data_numberlong>`.

* - ``maximum``

- document

- The exclusive upper bound of the range of :term:`shard key` values.

Specify each field of the shard key in the form of ``<fieldname> : <value>``.
The value must be of the same BSON type or types as the shard key.




.. note::

To use hashed sharding, the field value needs to be of type
:bsontype:`NumberLong <data_numberlong>`.

* - ``zone``

- string

- The name of the zone to associate with the range of shard key values bounded
by ``minimum`` and ``maximum``.





Only issue :method:`sh.updateZoneKeyRange()` when connected to a
Expand Down