I am creating unique neo4j relationships in java class based on no. of column values in database. Value of column "Interface_Name" will be assigned to each relationship.My Code :
while (rs.next()){
String rel = rs.getString("Interface_Name");
GraphDatabaseService graphDb = new EmbeddedGraphDatabase("D://My Graph");
Transaction tx = graphDb.beginTx();
try {
RelationshipType rel = DynamicRelationshipType.withName(rel); **//Gives error since rel is string**
.....
tx.success();
}
}
How can i create relationship Types based on Column values in DB?Inside while loop Relationship Types should get created according to DB values.