Skip to content

Maps

Map is a composite data type. A composite data type cannot be stored as properties. Maps are unordered collections of key-value pairs. In maps, the key is a string. The value can have any data type. You can get the map element by using map['key'].

Literal maps

nebula> YIELD {key: 'Value', listKey: [{inner: 'Map1'}, {inner: 'Map2'}]}
+-------------------------------------------------------------+
| {key:Value,listKey:[{inner:Map1},{inner:Map2}]}             |
+-------------------------------------------------------------+
| {key: "Value", listKey: [{inner: "Map1"}, {inner: "Map2"}]} |
+-------------------------------------------------------------+

OpenCypher compatibility

  • A composite data type (i.e. set, map, and list) CANNOT be stored as properties of vertices or edges.
  • Map projection is not supported.

Last update: March 16, 2021