1

I currently use orientdb as my graph DB. It is based on an underlying document db which supports ordered lists, and thus orientdb allows you to store edges in an order by doing something like this person.createEdgeProperty(Direction.OUT, "Photos").setOrdered(true);. This is extremely useful when dealing with trees of ordered data (e.g. parent has child 1 2 and 3) as you don't need to invent another way to add order to them in a graph (e.g. by modelling your tree as a linked list where parent has a edge to child 1, which has an edge to child 2...).

My question is whether there are any other graph DB's out there that allow you to store ordered edges such that modelling tree structures is easy. I am pretty sure neo4j can not, does anyone know about DEX or Titan or any of the other graph databases?

gremwell
  • 1,419
  • 17
  • 23
  • Any tinkerpop-compatible (`blueprints`, `gremlin` buzzwords) graph database should do. See http://gremlindocs.com/#transform/order and http://www.tinkerpop.com/docs/3.0.0.M7/#order-step – xmojmr Feb 27 '15 at 07:36
  • 1
    That implies that I have captured the order of children in the data, where as in orient if you set it to ordered the it will come out in that order _without_ needing to do some sort of ordering step. This is convenient as it means you don't need to maintain the order details in your data (e.g. an insert in the front would have to update all the nodes after it, alternative is to do it as a linked list which makes insertion easy but traversal is now X hops) – gremwell Feb 28 '15 at 22:45
  • 1
    True, but defining the ordering (with some custom data attribute) explicitly is quite common when treating data as sets. E.g. in the world of relational databases (`SQL`) in contrast to navigational databases the ordering is in general undefined and it is programmer's responsibility. Some orderings may be better optimized (primary key index, autoincrement keys) but it does not change the core concept: programmer has to define the ordering, database engine has to support it. I'm just saying that as long as you define the ordering, any tinkerpop-compatible graph database engine will support it – xmojmr Mar 01 '15 at 07:17
  • So I guess the answer to the question is "no". I gather that this is a niche where orientdb's "Document Graph" gives it this unique attribute of being able to order the edges without needing additional data (underneath it uses a list instead of a set) – gremwell Mar 02 '15 at 09:42
  • I **don't know** what's the correct answer, neither whats available on the graph-database market, but `OrientDB` came out as good choice in my recent (shallow) survey and although older youtube videos said `Titan` is cool, the current state of affairs indicates that [Titan is not serious choice](http://stackoverflow.com/a/28596112/2626313). However, avoiding vendor-lock in your code and sticking to a _standard_ like `tinkerpop3` would be my preferred followup action (whatever the satisfactory answer to your question might say) – xmojmr Mar 02 '15 at 11:21
  • 2
    To follow up on this, we actually did go with orientdb but hit so many damn bugs we ended up moving away from it as we were spending too much time debugging issues in their database rather than building our own product. – gremwell Jan 29 '16 at 05:36

0 Answers0