property

Synopsis

property [ "*csv_column*" ] "*propertyName*"

Description

Identifies a property of a vertex to the given field name that will be mapped onto a property from an input data file. If a CSV column is named differently than the field in the graph, the CSV column name may be optionally set. If no property is set, all properties are read. If ignore is used, a property will be bypassed.

During the graphloader stage 1 schema discovery, if a property key sequentially occurs multiple times on the same vertex, then the property is considered to be a multi-property. This is a reasonable deduction; however, it might change the discovered schema in certain fringe cases. Typically, in JSON input data, nested lists are mapped to multi-cardinality properties and should be read in that manner. If multi-cardinal fields exist in the input file, schema must define those elements prior to loading. Another example is a JDBC column that is of data type java.sql.Array.

Examples

Set property in a mapping script to gender. The values of the property will be read based on the values set in the value field of badge.

property "gender"

For this mapping, the data could be:

{ "name":"Jane Doe", "gender":"M" }

Set property to read a column nick in a CSV file to nickname in a mapping script.

property "nick" "nickname"

For this mapping, the data could be:

name, nick
Jane Doe|Janey

Was this helpful?

Give Feedback

How can we improve the documentation?

© 2024 DataStax | Privacy policy | Terms of use

Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Pulsar, Pulsar, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries. Kubernetes is the registered trademark of the Linux Foundation.

General Inquiries: +1 (650) 389-6000, info@datastax.com