ArangoDB Manual Pages
Users can pick names for their collections as desired, provided the following naming constraints are not violated:
- Collection names must only consist of the letters
z(both in lower and upper case), the numbers
9, the the underscore (
_), or the dash (
-) symbol. This also means that any non-ASCII collection names are not allowed.
- Collection names must start with a letter (not a number, the underscore or the dash character). Collection names starting with an underscore are considered to be system collections that are for ArangoDB's internal use only. System collection names should not be used by end users for their own collections.
- The maximum allowed length of a collection name is 64 bytes.
- Collection names are case-sensitive.
Users can define their own keys for documents they save. The document key will be saved along with a document in the
_key attribute. Users can pick key values as required, provided that the values conform to the following restrictions:
- the key must be at most 254 bytes long
- it must consist of the letters a-z (lower or upper case), the digits 0-9, the underscore (_), dash (-), or colon (:) characters only
- any other characters, especially multi-byte sequences, whitespace or punctuation characters cannot be used inside key values
- the key must be unique within the collection it is used
Keys are case-sensitive, i.e.
MyKEY are considered different keys.
Specifiying a document key is optional when creating new documents. If no document key is specified by the user, ArangoDB will create the document key itself as each document is required to have a key.
There are no guarantees about the format and pattern of auto-generated document keys other than the above restrictions. Clients should therefore treat auto-generated document keys as opaque values and not rely on their format.
Users can pick attribute names for document attributes as desired, provided the following attribute naming constraints are not violated:
Attribute names starting with an underscore are considered to be system attributes for ArangoDB's internal use. Such attribute names are already used by ArangoDB for special purposes, e.g.
_idis used to contain a document's handle,
_keyis used to contain a document's user-defined key, and
_revis used to contain the document's revision number. In edge collections, the
_toattributes are used to reference other documents.
More system attributes may be added in the future without further notice so end users should not use attribute names starting with an underscore for their own attributes.
- Attribute names should not start with the at-mark (
\@). The at-mark at the start of attribute names is reserved in ArangoDB for future use cases.
- ArangoDB does not enforce a length limit for attribute names. However, long attribute names may use more memory in result sets etc. Therefore the use of long attribute names is discouraged.
- As ArangoDB saves document attribute names separate from the actual document attribute value data, the combined length of all attribute names for a document must fit into an ArangoDB shape structure. The maximum combined names length is variable and depends on the number and data types of attributes used.
- Attribute names are case-sensitive.