Hi,

I have a graph database. The nodes in the graph suppose to be connected based on the order of the given property values. For example, the graph nodes can be:

**(a{p:1}) (b{p:3}) (c{p:6}) (d{p:8})**

then the connections suppose to be:

**a--b--c--d**

according to the order of the p value.

Where the problem is that the p values are randomly given.

So, how can I create the relationships between the nodes by Cypher?

Could you guys give me any suggestions? Thanks a lot!