Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Feels like a stupid question, but...
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
betseyb  
View profile  
 More options Oct 11 2012, 3:56 pm
From: betseyb <betsey.ben...@bostonfusion.com>
Date: Thu, 11 Oct 2012 12:56:55 -0700 (PDT)
Local: Thurs, Oct 11 2012 3:56 pm
Subject: Feels like a stupid question, but...

I want to write a Java program to use a BatchInserter to set up a database,
which I will then access via the REST API from another application.  The
BatchInserter requires that I provide a directory for my database, but
there doesn't appear to be any examples of how to use that directory in the
REST API.  What am I missing??

Thanks!


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Michael Hunger  
View profile  
 More options Oct 11 2012, 7:46 pm
From: Michael Hunger <michael.hun...@neotechnology.com>
Date: Fri, 12 Oct 2012 01:45:46 +0200
Local: Thurs, Oct 11 2012 7:45 pm
Subject: Re: [Neo4j] Feels like a stupid question, but...
You point your graphdatabase-location setting in the server/conf/neo4j-server.properties to the directory or just copy it into server/data/graph.db

HTH

Michael

Am 11.10.2012 um 21:56 schrieb betseyb:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
betseyb  
View profile  
 More options Oct 12 2012, 10:44 am
From: betseyb <betsey.ben...@bostonfusion.com>
Date: Fri, 12 Oct 2012 07:44:22 -0700 (PDT)
Local: Fri, Oct 12 2012 10:44 am
Subject: Re: [Neo4j] Feels like a stupid question, but...

Thank you!  I've been trying to read through the manual and the tutorials,
and it seems like there are a lot of missing details that make it difficult
to understand.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter Neubauer  
View profile  
 More options Oct 15 2012, 9:08 am
From: Peter Neubauer <peter.neuba...@neotechnology.com>
Date: Mon, 15 Oct 2012 15:07:57 +0200
Local: Mon, Oct 15 2012 9:07 am
Subject: Re: [Neo4j] Feels like a stupid question, but...
Hi there,
if you can compile a list of things that are confusing to you, it
would be most appreciated in order to make the docs better!

Cheers,

/peter neubauer

G:  neubauer.peter
S:  peter.neubauer
P:  +46 704 106975
L:   http://www.linkedin.com/in/neubauer
T:   @peterneubauer

Neo4j 1.8 GA - http://www.dzone.com/links/neo4j_18_release_fluent_graph_literacy.html


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
betseyb  
View profile  
 More options Oct 17 2012, 12:08 pm
From: betseyb <betsey.ben...@bostonfusion.com>
Date: Wed, 17 Oct 2012 09:08:17 -0700 (PDT)
Local: Wed, Oct 17 2012 12:08 pm
Subject: Re: [Neo4j] Feels like a stupid question, but...

OK, I"m really confused.

My neo4j-server.properties has:
# location of the database directory
org.neo4j.server.database.location=data/graph.db

My Java code using a BatchInserter to insert nodes is:

BatchInserter db =  null;
BufferedReader reader = null;
 DateFormat  df = new SimpleDateFormat("yyyy/MM/dd");
Date today = new Date();
 try {
File graphDb = new File("data/graph.db");
if (graphDb.exists()) {
FileUtils.deleteRecursively(graphDb);

}

long nodes = 0;
 Map<String, String> config = new HashMap<String, String>();
 db = BatchInserters.inserter(dbpath);
reader = new BufferedReader(new FileReader(new File(nodeFile)));
System.out.println("Loading nodes..");
reader.readLine();
String line = null;
while ((line = reader.readLine()) != null) {
String[] lineData = line.split(",");
 Map<String, Object> prop = new HashMap<String, Object>(10);
prop.put("Name", lineData[0]);
prop.put("Type", lineData[1]);
prop.put("DateCreated", today.getTime());
createNode(lineData[0], db, prop);
nodes++;

}

System.out.println("Total nodes: "+nodes);

reader.close();

It executes successfully, but when I try to look at the database from the
web interface, I don't see anything there.  I also tried prepending
'server' to the directory, with no luck.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Michael Hunger  
View profile  
 More options Oct 18 2012, 1:42 am
From: Michael Hunger <michael.hun...@neotechnology.com>
Date: Thu, 18 Oct 2012 01:42:09 -0400
Local: Thurs, Oct 18 2012 1:42 am
Subject: Re: [Neo4j] Feels like a stupid question, but...

Probably you should use absolute paths in your batch inserter to make sure it ends up in the right place, otherwise it will be data/graph.db from the base of your java project (you might have to copy that).

Don't forget to stop your server before that and start if afterwards

Michael

Am 17.10.2012 um 12:08 schrieb betseyb:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »