gremlin - how to create a list of string using groovy -


suppose want collect bookname follows:

x = g.v.has("books").bookname 

it shows outpuat :

=>groovy =>java =>oracle 

..

i want create list above in following manner :

x = ["groovy","java","oracle"] 

how create above list can iterate list further ?

you can use tolist() method, query becomes:

x = g.v.has("books").bookname.tolist() 

Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -