Using Neo4j 3.0.6 from Terminal

68 views
Skip to first unread message

Mhammed Najim

unread,
Nov 3, 2016, 6:49:24 PM11/3/16
to Neo4j
Dear all programmers,
I'm beginner user to Neo4j. I Installed the last version of Neo4j (3.0.6). I can't use Neo4j from the terminal and also i couldn't open the Webadmin. 
thanks

Michael Hunger

unread,
Nov 3, 2016, 7:06:15 PM11/3/16
to ne...@googlegroups.com
There is no Webadmin in Neo4j 3.0.x just neo4j browser on localhost:7474/browser

I presume you installed the desktop app.

Why would you want to use it from the terminal? If you need the version for the terminal, download  the "tar" variant from 

Michael


--
You received this message because you are subscribed to the Google Groups "Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email to neo4j+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Mhammed Najim

unread,
Nov 4, 2016, 11:57:15 AM11/4/16
to Neo4j
Dear Michael !
thanks to your answer. Actually I Installed the desktop app as you presumed, and the reason to why I want use it from the terminal:  because I have CSV data are ready to  import, I’ve followed  the neo4j guide (https://neo4j.com/developer/guide-import-csv/)  which explain how to import CSV file in Neo4j, I did what she referred  in video, when she created  some Constraints, and Nodes with their  relationships as a  cypher codes  on "Sublime",  According to  the data model which she made, and then she  executed from Neo4j terminal as a Golden way to  test and import CSV data. I almost did the same way on "Sublime" also  , but I couldn’t execute that codes from terminal as she did, because of   my Neo4j's terminal  didn't  appear, That's why I wondered about the Webadmin as an alternative to Neo4j dashboard terminal, and also I tried to execute my Cypher syntax from  Neo4j interface, also it won’t execute. 
these are my cypher codes with I talked about .

CREATE CONSTRAINT ON (s:DD_Survey_12IN) ASSERT s.SURV12_ID is UNIQUE; 
CREATE CONSTRAINT ON (c:DR_Casing_9IN)  ASSERT c.CAS9_ID   is UNIQUE;
CREATE CONSTRAINT ON (w:WL_CBL_9IN)     ASSERT w.CBL9_ID   is UNIQUE;

//SURVEY, CASING, CBL.
USING PERIODIC COMMIT 
LOAD CSV with headers FROM "file:/V_CBL+CAS+Survey12in.csv" AS line
WITH line, split(line.Timing, '/') as time

CREATE (survey:HF4_3_2H:DD_Survey_12IN {SURV12_ID: ToFloat (line.SURV12_ID)})
    set survey.houre                    =TOINT (time[2]),
        survey.minutes                  =TOINT(time[0]),
        survey.second                   =TOINT(time[1]),
        survey.Sur12_WellDepth          =ToFloat (line.SUR12_Well depth), 
        survey.Sounding                 =ToFloat (line.sounding),
        survey.Well_Oblique             =ToFloat (line.Well oblique),
        survey.Position                 =ToFloat (line.position),
        survey.Heavy_Surface            =ToFloat (line.Heavy surface),
        survey.surface.Magnetic_surface =ToFloat (line.Magnetic surface),
        survey.Gravity                 =ToFloat (line.Gravity),
        survey.Magnetic_field_intensity =ToFloat (line.Magnetic field intensity),
        survey.Magnetic_inclination     =ToFloat (line.Magnetic inclination),
        survey.temperature             =ToFloat (line.temperature),
        survey.GX                       =ToFloat (line.Gx),
        survey.GY                       =ToFloat (line.Gy),
        survey.GZ                       =ToFloat (line.Gz),
        survey.BX                       =ToFloat (line.Bx),
        survey.BY                       =ToFloat (line.By),
        survey.BZ                       =ToFloat (line.Bz)

CREATE (casing:HF4_3_2H:DR_Casing_9IN {CAS9_ID: ToFloat (line.CAS9_ID)})
    set casing.CAS9_No                  =ToFloat (line.CAS_No., 
        casing.CAS9_Factory             =line.CAS_Factory,
        casing.CAS9_Grade               =line.CAS_Grade,
        casing.CAS9_Thickness_mm        =ToFloat (line.CAS_Thickness_mm),
        casing.CAS9_OD_mm               =ToFloat (line.CAS_OD_mm),
        casing.CAS9_SubLength_m         =ToFloat (line.CAS_Sub Length_m),
        casing.CAS9_TotalLenght_m       =ToFloat (line.CAS_Total Length_m),
        casing.CAS9_Depth_m             =ToFloat (line.CAS_Depth_m),
        casing.CAS9_Remarks             =ToFloat (line.CAS_Remark)

CREATE (cbl:HF4_3_2H:WL_CBL_9IN       {CBL9_ID: ToFloat (line.CBL9_ID)})
    set cbl.CBL_Depth_m                 =ToFloat (line.CBL_DEPTH_m),
        cbl.CBL_TEN_KG                  =ToFloat (line.CBL_TEN_KG),
        cbl.CBL_GR_GAPI                 =ToFloat (line.CBL_GR_GAPI),
        cbl.CBL_CCL_mv                  =ToFloat (line.CBL_CCL_mv),
        cbl.CBL_mv                      =ToFloat (line.CBL_mv),
        cbl.CBL_WF1                     =ToFloat (line.CBL_WF1)

CREATE (casing)-[a:Correlation_Incl]->(survey)
CREATE (cbl)   -[a:Correlation_Incl]->(survey)
CREATE (cbl)   -[r:Correlation_CCL]->(casing)
 set a.Incl = CASE line.Magnetic inclination WHEN 0 then false ELSE true  END, 
     r.ccl  = CASE line.CBL_CCL_mv           WHEN 0 THEN false ELSE true  END
     ;

Mhammed Najim

unread,
Nov 4, 2016, 12:20:13 PM11/4/16
to ne...@googlegroups.com
Dear Michael !
thanks to your answer. Actually I Installed the desktop app as you guessed, and the reason to why I want use it from the terminal:  because I have CSV data are ready to  import, I’ve followed  the neo4j guide (https://neo4j.com/developer/guide-import-csv/)  which explain how to import CSV file in Neo4j, I did what she referred  in video, when she created  some Constrain and Nodes with relationships as a  cypher codes  on "Sublime",  according to  the data model, and  then she  executed on Neo4j terminal as a Golden way to  test and import CSV to. I almost did the same on "Sublime" also  , but I couldn’t execute that codes on terminal as she did because Neo4j's terminal  didn't  appear , I tried to execute my Cypher syntax  on Neo4j interface,but  it won’t execute. these are my cypher syntax  codes which I talked about :
You received this message because you are subscribed to a topic in the Google Groups "Neo4j" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/neo4j/1fnzsE0TuXo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to neo4j+un...@googlegroups.com.

Michael Hunger

unread,
Nov 5, 2016, 5:07:43 AM11/5/16
to ne...@googlegroups.com
Just use the script from the gist I shared to start a neo4j-shell and then past your code.

on mac:
java -cp /Applications/Neo4j\ Community\ Edition.app/Contents/Resources/app/bin/neo4j-desktop-3.0.2.jar org.neo4j.shell.StartClient "$@"

on windows:
"C:\Program Files\Neo4j Community\jre\bin\java" -cp "C:\Program Files\Neo4j Community\bin\neo4j-desktop-3.0.2.jar" org.neo4j.shell.StartClient %*

--

Mhammed Najim

unread,
Nov 5, 2016, 5:39:54 AM11/5/16
to ne...@googlegroups.com
Thank you very much brother )
You received this message because you are subscribed to a topic in the Google Groups "Neo4j" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/neo4j/1fnzsE0TuXo/unsubscribe.

To unsubscribe from this group and all its topics, send an email to neo4j+un...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages