title: How to model Graph data in Postgresql?
body: <p>How would one go about storing and querying sparse directed or undirected graphs in Postgresql. There is something like <a href="http://pgfoundry.org/projects/pggraph" rel="noreferrer">pggraph</a>, but that is still in planning stage.</p>
  
  <p>I realize dedicated graph databases like Neo4J are best suited for this. However is there way to implement same within Postgresql, by using extension or a data type, which would avoid adding another database engine.dtata</p>