Order by relationship properties neo4j -


using neo4j 1.9.3 -

i want create music program listing. on given program there may 3 pieces being performed. each piece has composer associated them, , may appear on many different programs, can't put sequence numbers on piece nodes.

i assume can create program, relationships each piece such:

(program1)-[:program_piece {program_seq: 1}]->(piece1) (program1)-[:program_piece {program_seq: 2}]->(piece2) (program1)-[:program_piece {program_seq: 3}]->(piece3) 

my question is, how query graph list pieces in correct order using relationship property "program_seq"? i'm fine using order node properties, have not been successful relationships (story of life...)

if it, lock down: is, bind variable. can use order by same way node properties. if have retrieved program (program1) can like

match (program1)-[r:program_piece]->(piece1)   return program1, r, piece1   order r.program_seq 

Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

c++ - Correct method for redrawing a layered window -

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