Manage Group IDs
This page provides guidance for managing group IDs if they are enabled on your key-value collection.
List Group IDs
To list all group IDs in a collection:
Follow the instructions to Run a Query in the Console or Run a Query with the CLI.
Run the following query:
FOR doc IN @@collectionName
COLLECT groups = doc.groupID
LIMIT @offset, @limit
RETURN groups
Update Group IDs
To update all key-value pairs belonging to old groupID with new groupID in a collection:
Follow the instructions to Run a Query in the Console or Run a Query with the CLI.
Run the following query:
FOR doc IN @@collectionName
FILTER doc.groupID == @oldGroupID
UPDATE doc._key WITH {groupID: @newGroupID} IN @@collectionName RETURN doc._key