labelField "*fieldName*"


Sets the label of the vertex to the name associated with the given field in the input data file. The vertex label must already exist.

labelField can be used in both vertex and incident edge mapping (inE, outE).


Set the label in a mapping script to the field name type.

labelField "type"

The contents of the field type will designate the vertex label. For instance, if a record in the data file has the field type entered as author, then the record will be read into a vertex with the vertex label set to author. The next record might instead have a value of recipe for the type field, and the data will be read into a vertex with a vertex label set to recipe. Thus, mixed sets of data can be read from a single input data file.

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,