}
void shutdown()
{
graphservice.shutdown();
System.out.println("graph Service is shut downing ......................");
}
}
and know i try see the relationship on neoeclipse but i failed.
when i select database location then i will giving the projectworkspace location then it will giving a single node which is coming default not my code.
and when i am giving database location "private static final String dbpath=C:/Users/Administrator/Desktop/anurag/demo1" then giving error.
Hi admin,
package com.graph;
import org.neo4j.graphdb.Direction; import org.neo4j.graphdb.GraphDatabaseService; import org.neo4j.graphdb.Node; import org.neo4j.graphdb.Relationship; import org.neo4j.graphdb.RelationshipType; import org.neo4j.graphdb.Transaction; import org.neo4j.graphdb.factory.GraphDatabaseFactory;
public class VisualGraph {
public static void main(String...s) {
VisualGraph visual = new VisualGraph(); visual.createDatabaseConnection(); //visual.removenotes(); visual.shutdown(); }
void createDatabaseConnection() { graphservice = new GraphDatabaseFactory().newEmbeddedDatabase(dbpath); Transaction transaction = graphservice.beginTx(); try {
} void removenotes() { Transaction transaction = graphservice.beginTx(); try { FirstNode.getSingleRelationship( Relation.KNOWS, Direction.OUTGOING ).delete(); System.out.println("RelationShips are deleted...."); FirstNode.delete(); SecondNode.delete(); System.out.println("nodes are deleted......"); transaction.success();
} void shutdown() { graphservice.shutdown(); System.out.println("graph Service is shut downing ......................"); } }
and know i try see the relationship on neoeclipse but i failed.
when i select database location then i will giving the projectworkspace location then it will giving a single node which is coming default not my code.
and when i am giving database location "private static final String dbpath=C:/Users/Administrator/Desktop/anurag/demo1" then giving error.
please tell me admin i am very new in neocplise.