I'm fairely new to HypergraphDB and was running few tests to see how things are working and encountered this problem. I have created a hypergraph with different HGRel and I want to get the ones with a specific name and was trying to use the following code
List<HGRel> r = hg.getAll(graph, hg.and(hg.type(HGRel.class), hg.eq("name", "XXX")));
basically I want to find all hyperedges that is named "XXX" but unfortunately I am getting this error
java.lang.RuntimeException: org.hypergraphdb.HGException: Could not find projection for 'name' in HG type a5edd585-2d5c-4555-8fdf-f9954bd35fe9 for HGRel
at org.hypergraphdb.transaction.HGTransactionManager.ensureTransaction(HGTransactionManager.java:324)
at org.hypergraphdb.query.cond2qry.ExpressionBasedQuery.<init>(ExpressionBasedQuery.java:812)
at org.hypergraphdb.HGQuery.make(HGQuery.java:174)
at org.hypergraphdb.HyperGraph.find(HyperGraph.java:1524)
at org.hypergraphdb.HGQuery$hg$10.call(HGQuery.java:1753)
at org.hypergraphdb.HGQuery$hg$10.call(HGQuery.java:1)
at org.hypergraphdb.transaction.HGTransactionManager.transact(HGTransactionManager.java:400)
at org.hypergraphdb.transaction.HGTransactionManager.ensureTransaction(HGTransactionManager.java:327)
at org.hypergraphdb.HGQuery$hg.getAll(HGQuery.java:1746)
I can always get all HGRel and filter on the application but I was wondering what I am doing wrong in here. Thank you in advance