[Neo4j] Re: Is there any Graph Visualisation Tool with the Name "GraphDB".If there how can i use that Tool with Neo4j.

2019-01-06 Thread Tom Zeppenfeldt
I don't know of any tool of that name. Depending on your needs, I suggest 
to have a look at www.graphileon.com  (of which I am one of the members) . 
We have a free personal edition for Mac, Windows, Linux.

Best,

Tom



On Monday, 6 August 2018 15:08:28 UTC+2, Srinivas Bonigiri wrote:
>
> Is there any Graph Visualisation Tool with the Name "GraphDB".If there how 
> can i use that Tool with Neo4j.
>

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] neo4j browser display nodes as images

2016-12-26 Thread Tom Zeppenfeldt
Koen,

are you referring to this tweet of by Rik ?  
https://twitter.com/rvanbruggen/status/804407817952174084

> 
> On 26 Dec 2016, at 15:50, koen  wrote:
> 
> Hi, i a recent post of Rik i saw that starting with neo4j 3.1 you can display 
> a picture / icon representing a node in the browser _i.s.o. the circle)  ,, 
> where is it documented how to do that ?
> 
> thanks koen
> 
> -- 
> 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+unsubscr...@googlegroups.com 
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Diff two graphs

2016-05-07 Thread Tom Zeppenfeldt
You might try this ( 
http://portal.graphgist.org/graph_gists/5e3d1fdf-d14d-4e0f-80a9-bbf344ea3e07 
  
)   approach. It also allows you to keep track of changes and view previous 
versions

Best,

Tom
> On 02 May 2016, at 17:42, MS  wrote:
> 
> Hi,
> 
> Is there a way in which a diff report can be created between two similar 
> graphs. The goal is to understand evolution by comparing two nodes their 
> child nodes their attributes and edges. 
> 
> Thanks,
> MS
> 
> -- 
> 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+unsubscr...@googlegroups.com 
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] WITH only applies to first element of UNION ?

2015-06-04 Thread Tom Zeppenfeldt
Michael,

Thanks.  At least it's not something that I did wrong :)   You say  yet..
 is it something that will be possible in future versions?


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2015-06-04 18:25 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 Tom,

 UNION does not support post-processing past the union yet. So with is only
 applied to the first part and you would have to replicate that with.

 Or you just send two statements.

 HTH Michael

 Am 01.06.2015 um 03:52 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 *For a faceted search I first do a MATCH on multiple conditions, and then
 count the remaining facet values. *


 match


 (n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 {year:2013}),

 (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location {name:'Netherlands'} )

 with n

 //location facet

 MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location)
 RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount
 order by facetcount

 UNION

 //month facet

 MATCH
 (n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year)
 RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount
 order by facetcount;

 +---+

 | facet  | facetvalue  | facetcount |

 +---+

 | Location | Noord-Brabant | 3  |

 | Location | Gelderland| 4  |

 | Location | Groningen | 4  |

 | Location | Zuid-Holland  | 4  |

 | Location | Overijssel| 5  |

 | Location | Flevoland | 5  |

 | Location | Friesland | 6  |

 | Location | Utrecht   | 8  |

 | Location | Limburg   | 8  |

 | Location | Drenthe   | 10 |

 | Location | Noord-Holland | 10 |

 | Location | Zeeland   | 12 |

 | Location | Netherlands   | 90 |

 | Period   | 6   | 142|

 | Period   | 12  | 155|

 | Period   | 3   | 156|

 | Period   | 4   | 162|

 | Period   | 11  | 164|

 | Period   | 7   | 164|

 | Period   | 1   | 167|

 | Period   | 2   | 171|

 | Period   | 8   | 172|

 | Period   | 5   | 175|

 | Period   | 10  | 177|

 | Period   | 9   | 195|

 +---+

 *when I switch the two elements of the UNION, so first the month facet and
 then the location facet, I get different counts ( I don't meant that the
 results are in another order, b/c that's obvious) , but it seems that the
 WITH is only applied to the first element of UNION*


 neo4j-sh (?)$ match
 (n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 {year:2013}),

(n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location
 {name:'Netherlands'} )

  with n

  //month facet

  MATCH
 (n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year)

  RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount
 order by facetcount

  UNION

  //location facet

  MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location)

  RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount
 order by facetcount;

 +---+

 | facet  | facetvalue  | facetcount |

 +---+

 | Period   | 7   | 4  |

 | Period   | 12  | 6  |

 | Period   | 11  | 6  |

 | Period   | 6   | 7  |

 | Period   | 8   | 7  |

 | Period   | 2   | 7  |

 | Period   | 4   | 7  |

 | Period   | 3   | 8  |

 | Period   | 10  | 8  |

 | Period   | 9   | 9  |

 | Period   | 5   | 10 |

 | Period   | 1   | 11 |

 | Location | Noord-Brabant | 135|

 | Location | Limburg   | 140|

 | Location | Overijssel| 142|

 | Location | Friesland | 144|

 | Location | Utrecht   | 147|

 | Location | Groningen | 147|

 | Location | Flevoland | 154|

 | Location | Noord-Holland | 160|

 | Location | Drenthe   | 161|

 | Location | Zuid-Holland  | 161|

 | Location | Gelderland| 165|

 | Location | Zeeland   | 171|

 | Location | Netherlands   | 2012   |

 +---+

 --
 You received

Re: [Neo4j] WITH only applies to first element of UNION ?

2015-06-04 Thread Tom Zeppenfeldt
no one has a clue?


Met vriendelijke groet / With kind regards

Tom Zeppenfeldt

---
Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
E-mail: tomzeppenfe...@gmail.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2015-06-01 12:52 GMT+02:00 Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 *For a faceted search I first do a MATCH on multiple conditions, and then
 count the remaining facet values. *


 match


 (n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 {year:2013}),

 (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location {name:'Netherlands'} )

 with n

 //location facet

 MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location)
 RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount
 order by facetcount

 UNION

 //month facet

 MATCH
 (n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year)
 RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount
 order by facetcount;

 +---+

 | facet  | facetvalue  | facetcount |

 +---+

 | Location | Noord-Brabant | 3  |

 | Location | Gelderland| 4  |

 | Location | Groningen | 4  |

 | Location | Zuid-Holland  | 4  |

 | Location | Overijssel| 5  |

 | Location | Flevoland | 5  |

 | Location | Friesland | 6  |

 | Location | Utrecht   | 8  |

 | Location | Limburg   | 8  |

 | Location | Drenthe   | 10 |

 | Location | Noord-Holland | 10 |

 | Location | Zeeland   | 12 |

 | Location | Netherlands   | 90 |

 | Period   | 6   | 142|

 | Period   | 12  | 155|

 | Period   | 3   | 156|

 | Period   | 4   | 162|

 | Period   | 11  | 164|

 | Period   | 7   | 164|

 | Period   | 1   | 167|

 | Period   | 2   | 171|

 | Period   | 8   | 172|

 | Period   | 5   | 175|

 | Period   | 10  | 177|

 | Period   | 9   | 195|

 +---+

 *when I switch the two elements of the UNION, so first the month facet and
 then the location facet, I get different counts ( I don't meant that the
 results are in another order, b/c that's obvious) , but it seems that the
 WITH is only applied to the first element of UNION*


 neo4j-sh (?)$ match
 (n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 {year:2013}),

(n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location
 {name:'Netherlands'} )

  with n

  //month facet

  MATCH
 (n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year)

  RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount
 order by facetcount

  UNION

  //location facet

  MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location)

  RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount
 order by facetcount;

 +---+

 | facet  | facetvalue  | facetcount |

 +---+

 | Period   | 7   | 4  |

 | Period   | 12  | 6  |

 | Period   | 11  | 6  |

 | Period   | 6   | 7  |

 | Period   | 8   | 7  |

 | Period   | 2   | 7  |

 | Period   | 4   | 7  |

 | Period   | 3   | 8  |

 | Period   | 10  | 8  |

 | Period   | 9   | 9  |

 | Period   | 5   | 10 |

 | Period   | 1   | 11 |

 | Location | Noord-Brabant | 135|

 | Location | Limburg   | 140|

 | Location | Overijssel| 142|

 | Location | Friesland | 144|

 | Location | Utrecht   | 147|

 | Location | Groningen | 147|

 | Location | Flevoland | 154|

 | Location | Noord-Holland | 160|

 | Location | Drenthe   | 161|

 | Location | Zuid-Holland  | 161|

 | Location | Gelderland| 165|

 | Location | Zeeland   | 171|

 | Location | Netherlands   | 2012   |

 +---+

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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

[Neo4j] WITH only applies to first element of UNION ?

2015-06-01 Thread Tom Zeppenfeldt
*For a faceted search I first do a MATCH on multiple conditions, and then 
count the remaining facet values. *


match 


(n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 
{year:2013}),

(n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location {name:'Netherlands'} ) 

with n

//location facet

MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location) 
RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount 
order by facetcount

UNION

//month facet

MATCH 
(n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year) 
RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount 
order by facetcount;

+---+

| facet  | facetvalue  | facetcount |

+---+

| Location | Noord-Brabant | 3  |

| Location | Gelderland| 4  |

| Location | Groningen | 4  |

| Location | Zuid-Holland  | 4  |

| Location | Overijssel| 5  |

| Location | Flevoland | 5  |

| Location | Friesland | 6  |

| Location | Utrecht   | 8  |

| Location | Limburg   | 8  |

| Location | Drenthe   | 10 |

| Location | Noord-Holland | 10 |

| Location | Zeeland   | 12 |

| Location | Netherlands   | 90 |

| Period   | 6   | 142|

| Period   | 12  | 155|

| Period   | 3   | 156|

| Period   | 4   | 162|

| Period   | 11  | 164|

| Period   | 7   | 164|

| Period   | 1   | 167|

| Period   | 2   | 171|

| Period   | 8   | 172|

| Period   | 5   | 175|

| Period   | 10  | 177|

| Period   | 9   | 195|

+---+

*when I switch the two elements of the UNION, so first the month facet and 
then the location facet, I get different counts ( I don't meant that the 
results are in another order, b/c that's obvious) , but it seems that the 
WITH is only applied to the first element of UNION*


neo4j-sh (?)$ match 
(n:Document)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year
 
{year:2013}),

   (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location {name:'Netherlands'} 
) 

 with n

 //month facet

 MATCH 
(n)-[:PUBLISHED_ON]-(d:Day)-[:HAS_DAY]-(m:Month)-[:HAS_MONTH]-(y:Year) 

 RETURN 'Period' as facet,m.month as facetvalue, count(n) as facetcount 
order by facetcount

 UNION

 //location facet

 MATCH (n)-[:MENTIONED_IN|HAS_CHILD*1..]-(l:Location) 

 RETURN 'Location' as facet,l.name as facetvalue ,count(n) as facetcount 
order by facetcount;

+---+

| facet  | facetvalue  | facetcount |

+---+

| Period   | 7   | 4  |

| Period   | 12  | 6  |

| Period   | 11  | 6  |

| Period   | 6   | 7  |

| Period   | 8   | 7  |

| Period   | 2   | 7  |

| Period   | 4   | 7  |

| Period   | 3   | 8  |

| Period   | 10  | 8  |

| Period   | 9   | 9  |

| Period   | 5   | 10 |

| Period   | 1   | 11 |

| Location | Noord-Brabant | 135|

| Location | Limburg   | 140|

| Location | Overijssel| 142|

| Location | Friesland | 144|

| Location | Utrecht   | 147|

| Location | Groningen | 147|

| Location | Flevoland | 154|

| Location | Noord-Holland | 160|

| Location | Drenthe   | 161|

| Location | Zuid-Holland  | 161|

| Location | Gelderland| 165|

| Location | Zeeland   | 171|

| Location | Netherlands   | 2012   |

+---+

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Re: Nested collections problem

2015-05-14 Thread Tom Zeppenfeldt
Sumit,

yes it works, but if I want to order the results for instance on the basis
of the first label, i need to access nrms[0][0] . and that's where it fails.




Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2015-05-14 3:03 GMT+02:00 Sumit Gupta sumit1...@gmail.com:

 Hi Tom,

 your query works fine without Limit 1 too. it shows all the unique
 combinations of labelsn, labelm and typer, which is exactly your scope.

 And that's true that lablesn is not a collection, so what is the problem?
 or what is not working?

 Thanks,
 Sumit


 On Wednesday, 13 May 2015 03:47:12 UTC+5:30, Tom Zeppenfeldt wrote:

 In order to make a meta-model, i'd like to know what kind of nodes , rels
 are present in a db, as well as counts.

 Doing this


 *MATCH (n)-[r]-(m)*
 *WITH DISTINCT [labels(n),labels(m),type(r)] AS nrms, count(*) AS  countr*
 *WITH nrms[0] AS labelsn, nrms[1] AS labelsm, nrms[2] AS typer, countr*
 *RETURN labelsn,labelsm,typer,countr*


 works fine. with a LIMIT 1, the API returns this


 {
 columns: [
 labelsn,
 labelsm,
 typer,
 countr
 ],
 data: [
 [
 [
 Somelabel,
 Diagram
 ],
 [
 View
 ],
 CONTAINS,
 2
 ]
 ]
 }

 However, the labelsn and  labelsm in the RETURN don't seem to be
 collections. At least, I cannot do labelsn[0] or  length(labelsn)

 Accessing nrms[0][0] also produces an error.

 Running version 2.1.2




  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] INSERTing properties

2015-05-14 Thread Tom Zeppenfeldt
thanks.. this solves many issues on our side

best,

Tom


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2015-05-14 1:12 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com:

 you can simulate that by returning maps:

 RETURN {id:id(n), labels:labels(n), properties:n, metadata: some-value}
 as n


 Am 13.05.2015 um 11:14 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 We have a usecase in which styling of a node depends on the user and the
 (properties of a) relationship it has with other nodes. While trying to
 figure out how to do such a thing, we realized that it would be nice to
 have a possibility to insert properties in nodes or rels . Not SETting
 them and writing them to disk, but just inserting them in the result.

 MATCH (n)-[r]-(m)
 INSERT n.newproperty = r.someproperty, n.anotherproperty= m.xyz
 RETURN n LIMIT 1

 the result would be something like

 {
 columns: [n],
 data: [[{
 outgoing_relationships: 
 http://localhost:7474/db/data/node/37/relationships/out;,
 labels: http://localhost:7474/db/data/node/37/labels;,
 data: {},
 all_typed_relationships: 
 http://localhost:7474/db/data/node/37/relationships/all/{-list||types},
 traverse: 
 http://localhost:7474/db/data/node/37/traverse/{returnType};,
 self: http://localhost:7474/db/data/node/37;,
 property: 
 http://localhost:7474/db/data/node/37/properties/{key};,
 properties: http://localhost:7474/db/data/node/37/properties;,
 outgoing_typed_relationships: 
 http://localhost:7474/db/data/node/37/relationships/out/{-list||types},
 incoming_relationships: 
 http://localhost:7474/db/data/node/37/relationships/in;,
 extensions: {},
 create_relationship: 
 http://localhost:7474/db/data/node/37/relationships;,
 paged_traverse: 
 http://localhost:7474/db/data/node/37/paged/traverse/{returnType}{?pageSize,leaseTime}
 ,
 all_relationships: 
 http://localhost:7474/db/data/node/37/relationships/all;,
 incoming_typed_relationships: 
 http://localhost:7474/db/data/node/37/relationships/in/{-list||types},
 metadata: {
 id: 37,
 labels: [somelabel]
 },
 inserted: {
 newproperty: 1,
 anotherproperty: abc
 }
 }]]
 }

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] INSERTing properties

2015-05-13 Thread Tom Zeppenfeldt
We have a usecase in which styling of a node depends on the user and the 
(properties of a) relationship it has with other nodes. While trying to 
figure out how to do such a thing, we realized that it would be nice to 
have a possibility to insert properties in nodes or rels . Not SETting 
them and writing them to disk, but just inserting them in the result.

MATCH (n)-[r]-(m)
INSERT n.newproperty = r.someproperty, n.anotherproperty= m.xyz
RETURN n LIMIT 1

the result would be something like

{
columns: [n],
data: [[{
outgoing_relationships: 
http://localhost:7474/db/data/node/37/relationships/out;,
labels: http://localhost:7474/db/data/node/37/labels;,
data: {},
all_typed_relationships: 
http://localhost:7474/db/data/node/37/relationships/all/{-list||types},
traverse: 
http://localhost:7474/db/data/node/37/traverse/{returnType};,
self: http://localhost:7474/db/data/node/37;,
property: http://localhost:7474/db/data/node/37/properties/{key};
,
properties: http://localhost:7474/db/data/node/37/properties;,
outgoing_typed_relationships: 
http://localhost:7474/db/data/node/37/relationships/out/{-list||types},
incoming_relationships: 
http://localhost:7474/db/data/node/37/relationships/in;,
extensions: {},
create_relationship: 
http://localhost:7474/db/data/node/37/relationships;,
paged_traverse: 
http://localhost:7474/db/data/node/37/paged/traverse/{returnType}{?pageSize,leaseTime};
,
all_relationships: 
http://localhost:7474/db/data/node/37/relationships/all;,
incoming_typed_relationships: 
http://localhost:7474/db/data/node/37/relationships/in/{-list||types},
metadata: {
id: 37,
labels: [somelabel]
},
inserted: {
newproperty: 1,
anotherproperty: abc
}
}]]
}

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Nested collections problem

2015-05-12 Thread Tom Zeppenfeldt
In order to make a meta-model, i'd like to know what kind of nodes , rels 
are present in a db, as well as counts. 

Doing this


*MATCH (n)-[r]-(m)*
*WITH DISTINCT [labels(n),labels(m),type(r)] AS nrms, count(*) AS  countr*
*WITH nrms[0] AS labelsn, nrms[1] AS labelsm, nrms[2] AS typer, countr*
*RETURN labelsn,labelsm,typer,countr*


works fine. with a LIMIT 1, the API returns this


{
columns: [
labelsn,
labelsm,
typer,
countr
],
data: [
[
[
Somelabel,
Diagram
],
[
View
],
CONTAINS,
2
]
]
}

However, the labelsn and  labelsm in the RETURN don't seem to be 
collections. At least, I cannot do labelsn[0] or  length(labelsn)

Accessing nrms[0][0] also produces an error.

Running version 2.1.2




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] comparing collections of labels

2014-12-03 Thread Tom Zeppenfeldt
I have a usecase in which certain actions should only be triggered for 
specific nodetypes. a nodetype is defined by a *combination* of labels.

The nodetypes for which an action should take place is given by a nested 
collection of label combinations by something like  [[a, 
b],[a,d,e]]  . There has to be a exact match, so a node with only 
label a or  b, or a node with  :a:b:x  should not match.

Now the problem arises when I want to compare the  labels(n) with this 
collection, because [a, b] is different from  [a, b] , and there 
seems to be not a specific order in which labels are returned.

The only way I got this working is this

match (n) 
WHERE
(ALL (l in labels(n) WHERE l in ['a','b']) AND LENGTH(labels(n))=2)
OR
(ALL (l in labels(n) WHERE l in ['a','d','e']) AND LENGTH(labels(n))=3)
return n.name


If there was a way to predict the order of the labels , i would do this


match (n) 
WHERE 
 REDUCE(acc = '', p IN labels(n)| acc + p + ' ') IN ['a b ','a d e 
'] 
return n.name


Or is there another way?

Best, 

Tom

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Passing nested collection as cypher query parameter to REST endpoint

2014-12-02 Thread Tom Zeppenfeldt
I have an problem , probably related to passing a nested collection as a 
parameter to a cypher query..


In the browser, this works fine:

MATCH n-[r]-m 
WHERE id(n) = 0 
WITH CASE WHEN startnode(r)=n THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 
'OUT' END) ELSE 'IN' END as direction,type(r) as typer,m,r
WITH [labels(m),typer,direction] AS reltype
WHERE reltype IN 
*[[['Person'],'KNOWS','OUT'],[['Person'],'KNOWS','IN'],[['Prologram','User'],'KNOWS','IN']]*
RETURN reltype,count(*)

doing this using REST works fine too and also returns the expected result

*query*

{
  query : MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN startnode(r)=n 
THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 'OUT' END) ELSE 'IN' END as 
direction,type(r) as typer,m,r WITH [labels(m),typer,direction] AS reltype 
WHERE reltype IN 
[[['Person'],'KNOWS','OUT'],[['Person'],'KNOWS','IN'],[['Prologram','User'],'KNOWS','IN']]
 
RETURN reltype,count(*)
  }
} 

*result : *


{
columns: [
reltype,
count(*)
],
data: [
[
[
[
Person
],
KNOWS,
OUT
],
2
],
[
[
[
Prologram,
User
],
KNOWS,
IN
],
1
],
[
[
[
Person
],
KNOWS,
IN
],
1
]
]
}

however: passing the collection as a parameter does not work:

{
  query : MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN startnode(r)=n 
THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 'OUT' END) ELSE 'IN' END as 
direction,type(r) as typer,m,r WITH [labels(m),typer,direction] AS reltype 
WHERE reltype IN {reltypes} RETURN reltype,count(*),
  params: {
reltypes: 
[[[Person],KNOWS,OUT],[[Person],KNOWS,IN],[[Prologram,User],KNOWS,IN]]
  }
} 

returns an empty result

{
columns: [
reltype,
count(*)
],
data: []
}

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Passing nested collection as cypher query parameter to REST endpoint

2014-12-02 Thread Tom Zeppenfeldt
Hi michael.

I realized I had the same issue a couple of months ago.. will use the same
solution..

the weird thing however is that when doing it in the browser, the IN clause
allows to compare with nested objects.

http://stackoverflow.com/questions/25709309/syntax-issue-passing-objects-as-parameters-in-neo4j-cypher-statement
.

This is the profile output

neo4j-sh (?)$ export
reltypes=[[[Person],KNOWS,OUT],[[Person],KNOWS,IN],[[Prologram,User],KNOWS,IN]];
neo4j-sh (?)$ profile MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN
startnode(r)=n THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 'OUT' END)
ELSE 'IN' END as direction,type(r) as typer,m,r WITH
[labels(m),typer,direction] AS reltype WHERE reltype IN {reltypes} RETURN
reltype,count(*);
== ++
== | reltype | count(*) |
== ++
== ++
== 0 row
==
== ColumnFilter(0)
==   |
==   +EagerAggregation
== |
== +Filter
==   |
==   +ColumnFilter(1)
== |
== +Extract(0)
==   |
==   +ColumnFilter(2)
== |
== +Extract(1)
==   |
==   +TraversalMatcher
==
==
+--+--++-+-+
== | Operator | Rows | DbHits | Identifiers |
  Other |
==
+--+--++-+-+
== |  ColumnFilter(0) |0 |  0 | |
keep columns reltype, count(*) |
== | EagerAggregation |0 |  0 | |
reltype |
== |   Filter |0 |  0 | | any(-_-INNER-_- in
{reltypes} where reltype == -_-INNER-_-) |
== |  ColumnFilter(1) |   11 |  0 | |
  keep columns reltype |
== |   Extract(0) |   11 | 26 | |
reltype |
== |  ColumnFilter(2) |   11 |  0 | |
keep columns direction, typer, m, r |
== |   Extract(1) |   11 |  0 | |
  direction, typer |
== | TraversalMatcher |   11 | 13 | |
m, r, m |
==
+--+--++-+-+
==
Not sure how the  maps thing would work though..


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2014-12-02 12:17 GMT+01:00 Michael Hunger michael.hun...@neotechnology.com
:

 can you just try to return {reltypes}

 I think due to json parsing the nested collections in reltypes are turned
 into lists which are not equal to the type that is created by the literal
 syntax

 could you try a list of maps instead ?



 On Tue, Dec 2, 2014 at 11:18 AM, Tom Zeppenfeldt tomzeppenfe...@gmail.com
  wrote:

 I have an problem , probably related to passing a nested collection as a
 parameter to a cypher query..


 In the browser, this works fine:

 MATCH n-[r]-m
 WHERE id(n) = 0
 WITH CASE WHEN startnode(r)=n THEN (CASE WHEN endnode(r)=n THEN 'SELF'
 ELSE 'OUT' END) ELSE 'IN' END as direction,type(r) as typer,m,r
 WITH [labels(m),typer,direction] AS reltype
 WHERE reltype IN
 *[[['Person'],'KNOWS','OUT'],[['Person'],'KNOWS','IN'],[['Prologram','User'],'KNOWS','IN']]*
 RETURN reltype,count(*)

 doing this using REST works fine too and also returns the expected result

 *query*

 {
   query : MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN startnode(r)=n
 THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 'OUT' END) ELSE 'IN' END as
 direction,type(r) as typer,m,r WITH [labels(m),typer,direction] AS reltype
 WHERE reltype IN
 [[['Person'],'KNOWS','OUT'],[['Person'],'KNOWS','IN'],[['Prologram','User'],'KNOWS','IN']]
 RETURN reltype,count(*)
   }
 }

 *result : *


 {
 columns: [
 reltype,
 count(*)
 ],
 data: [
 [
 [
 [
 Person
 ],
 KNOWS,
 OUT
 ],
 2
 ],
 [
 [
 [
 Prologram,
 User
 ],
 KNOWS,
 IN
 ],
 1
 ],
 [
 [
 [
 Person
 ],
 KNOWS,
 IN
 ],
 1
 ]
 ]
 }

 however: passing the collection as a parameter does not work:

 {
   query : MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN startnode(r)=n
 THEN (CASE WHEN endnode(r)=n THEN 'SELF' ELSE 'OUT' END) ELSE 'IN' END as
 direction,type

Re: [Neo4j] Passing nested collection as cypher query parameter to REST endpoint

2014-12-02 Thread Tom Zeppenfeldt


 So this works:


{
  query : MATCH n-[r]-m WHERE id(n) = 0 WITH CASE WHEN startnode(r)=n 
THEN (CASE WHEN endnode(r)=n THEN ' SELF' ELSE ' OUT' END) ELSE ' IN' END 
as direction,type(r) as typer,REDUCE(acc = '', p IN labels(m)| acc + ' :'+ 
p) AS mlabels,r WITH typer+mlabels+direction AS reltype WHERE reltype IN 
{reltypes} RETURN reltype,count(*),
  params: {
reltypes: [
KNOWS :Person SELF,
KNOWS :Person IN,
KNOWS :Person OUT,
CONTAINS :Prologram :Diagram IN
]
  }
} 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: New Structr SNAPSHOT version - with integrated Neo4j server!

2014-11-12 Thread Tom Zeppenfeldt
Hi guys, I'm running the 11 snapshot now. The phrase You just have to add 
'Neo4jService' to the list of configured services is too cryptic for me. 
Just too many places where I can configure stuff, including services on my 
Mac. Any explication would be welcome.

Thanks

On Monday, 10 November 2014 14:46:20 UTC+1, Axel Morgner wrote:

 Hi Group, 

 glad to announce a new SNAPSHOT version of Structr, and it comes with 
 the long-awaited integrated Neo4j server! 

 You just have to add 'Neo4jService' to the list of configured services, 
 set host and port in the structr.conf and start as usual. Then you can 
 access the Neo4j browser on http://localhost:7474 (or whatever is set in 
 structr.conf *). 

 Warning: The Neo4j server runs against the same database as Structr, 
 bypassing all security measures. With the upcoming Neo4j 2.2, we'll 
 synchronise Structr's admin user with the user-level security of Neo4j. 
 Until then, make sure you don't expose the Neo4j listener to any 
 untrusted network! 

 Please note that this is an experimental build, but we're planning to 
 ship it with the 1.1 release. 

 Best, 
 Axel 


 (*) You can find the new config options in structr.conf_templ in the 
 structr-ui directory. 

 -- 
 Axel Morgner · CEO Structr (c/o Morgner UG) · Twitter @amorgner · Skype 
 axel.morgner 
 Hanauer Landstr. 291a · 60314 Frankfurt, Germany · Phone +49 151 40522060 
 https://structr.org - Structr: A revolutionary Software based on Neo4j 
 https://structr.com - Structr and Neo4j Hosting 



-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: New Structr SNAPSHOT version - with integrated Neo4j server!

2014-11-10 Thread Tom Zeppenfeldt
Hi Axel,

This sounds like fun. Surely will try to run our Prologram viz thingy 
against this server!

You state that it bypasses security. Does it also bypass any data-integrity 
rules like cardinality and other stuff we created through the Structr 
schema?

Best,

Tom

On Monday, 10 November 2014 14:46:20 UTC+1, Axel Morgner wrote:

 Hi Group, 

 glad to announce a new SNAPSHOT version of Structr, and it comes with 
 the long-awaited integrated Neo4j server! 

 You just have to add 'Neo4jService' to the list of configured services, 
 set host and port in the structr.conf and start as usual. Then you can 
 access the Neo4j browser on http://localhost:7474 (or whatever is set in 
 structr.conf *). 

 Warning: The Neo4j server runs against the same database as Structr, 
 bypassing all security measures. With the upcoming Neo4j 2.2, we'll 
 synchronise Structr's admin user with the user-level security of Neo4j. 
 Until then, make sure you don't expose the Neo4j listener to any 
 untrusted network! 

 Please note that this is an experimental build, but we're planning to 
 ship it with the 1.1 release. 

 Best, 
 Axel 


 (*) You can find the new config options in structr.conf_templ in the 
 structr-ui directory. 

 -- 
 Axel Morgner · CEO Structr (c/o Morgner UG) · Twitter @amorgner · Skype 
 axel.morgner 
 Hanauer Landstr. 291a · 60314 Frankfurt, Germany · Phone +49 151 40522060 
 https://structr.org - Structr: A revolutionary Software based on Neo4j 
 https://structr.com - Structr and Neo4j Hosting 



-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Specifying repeating path patterns in Cypher.

2014-10-31 Thread Tom Zeppenfeldt
would modeling this way work ?

(a:City)-[:FROM]-(f:Flight)-[:TO]-(b:City)

and matching it against

(a)-[:FROM|TO*2..12]-(b)


Having Flight nodes makes sense I guess, especially when you want to link
for instance crewmembers or passengers  to the flight.

HtH




Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt

2014-10-31 18:00 GMT+01:00 Mahesh Lal mahesh.2...@gmail.com:

 Hi,

 I have a problem in which I need to specify repeating path patterns in
 Cypher.

 The Problem:
 Find the route between two cities which aren't directly connected to each
 other.

 Original design:
 (a:City)-[:FLIGHT]-(b:City)

 To get the shortest route, I could simply run a query that specified
 (i:City{name:Istanbul})-[r:FLIGHT*1..6]-(l:City{name:Ulan Bator}) to
 say that the path length could be arbitrary, and then process the returned
 paths

 However, flight is a hyperedge, which means we need to model it
 differently.

 New Design:
 (a:City)-[:LEAVES_FROM]-(:Flight)-[:GOES_TO]-(b:City)

 How do I define a path of arbitrary length in this?

 Does the design even make sense from a semantic perspective?

 Any help would be appreciated.


 -- Thanks and Regards
Mahesh Lal

   --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Neo4j and ZUI

2014-09-06 Thread Tom Zeppenfeldt
ZUI  was not on our radar.  We looked into zoomcharts
https://zoomcharts.com/en/


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-09-06 23:48 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 I think Tom looked into that.

 Michael

 Am 05.09.2014 um 09:59 schrieb bruno menon bruno1.me...@gmail.com:

 Hello team,
 is some one ear something abous ZUI (zoom user Interface )
 http://eaglemode.sourceforge.net/philosophy.htmlfor Ne4j ?
 it's probably a wonderfull tool to add in graph exploration and Update.

 Thanks

 Bruno

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Any plans for an optional schema?

2014-07-16 Thread Tom Zeppenfeldt
sounds like structr.org may be something you want to look at ..




Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-07-16 22:28 GMT+02:00 Jason Gillman Jr. mackdaddydie...@gmail.com:

 I was just wondering if the ability to utilize a schema of sorts was on
 the road map.

 When I say schema, I'm thinking more along the lines of relational
 constraints.

 Let's use the following simple example.

 We have the following types of entities represented by node labels
 (:`Server`)
 (:`Switch`)
 (:`Physical Interface`)

 Then we would want to enforce the following relations (I would think these
 restrictions would seem intuitive):

 (:`Server`)-[:`Contains`]-(:`Physical Interface`)
 (:`Switch`)-[:`Contains`]-(:`Physical Interface`)
 (:`Physical Interface`)-[:`Connects`]-(:`Physical Interface`)


 Basically, to ensure data consistency without having to build it into an
 application, we would want it so that Neo4j would not allow, for example, a
 Server to connect to another Server, or a Switch, nor would we want to make
 a Physical Interface contain a Server.

 Is something like this in the plans? Of course the use of these
 constraints would be completely optional.

 Thanks!

 -Jason

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: Multiple hierarchical facets continued

2014-06-30 Thread Tom Zeppenfeldt
Hi all,

I'm still stuck here :( . Not sure what it means that I haven't received 
any suggestions. Is there no possibility to do this in a single query or is 
the question not clear?

Best,

Tom

On Wednesday, 25 June 2014 14:39:42 UTC+2, Tom Zeppenfeldt wrote:

 Hi all,

 Recently I worked with Michael Hunger on a typical faceted search case, 
 but since we haven't found the holy grail yet, I'm also sharing our 
 findings over here.

 The dropboxlink 
 https://www.dropbox.com/s/65rc2sz6p2lrpge/TomZepFacets.tar.gz contains a 
 Neo4j 2.1.2 db with about 6000 random nodes, modeled as follows (the db 
 also contains a :Meta model).  In terms of cardinality each :Datapoint has 
 1 :HAS_LOCATION and 1 :HAS_PERIOD relationship
 .[image: Inline afbeelding 1] 
 https://mail.google.com/mail/u/0/?ui=2ik=cffa13707eview=attth=146c0088c0e62770attid=0.1disp=embrealattid=ii_146beff0f2f2d71dzwatsh=1



 When requesting a filtered set of datapoints (with filters applied for a 
 country and a period of time)  I succeeded in getting the counts for one of 
 the facets, but not for both of them in a single cypher.

 The current approach is as follows:
 - retrieve all descendants of the filtervalue in the :Poi and  :Period 
 hierarchies, including the filtervalue itself. This results in a set of 
 nodes/leaves 
 - match all  :Datapoint nodes with the descendants. 


 neo4j-sh (?)$ cypher 2.1.experimental match 
 (poi)-[:HAS_CHILD*0..]-(poif)-[:HAS_CHILD*0..1]-(poiq:Poi {name: 
 Netherlands})
  with poi,poif
  match 
 (period)-[:HAS_CHILD*0..]-(periodf)-[:HAS_CHILD*0..1]-(periodq:Period 
 {name: 2014-Q2})
  with poif,periodf,poi,period
  match (poi)-[hl:HAS_LOCATION]-(dp)-[hp:HAS_PERIOD]-(period)
  with *poif*.name as fname ,count(distinct dp) as fcount
  return [fname,fcount] as facets;
 +---+
 | facets|
 +---+
 | [Overijssel,73] |
 | [Drenthe,31]|
 | [Utrecht,73]|
 | [Gelderland,143]|
 | [Flevoland,22]  |
 | [Netherlands,1089]  |
 | [Groningen,45]  |
 | [Noord-Holland,128] |
 | [Noord-Brabant,185] |
 | [Limburg,103]   |
 | [Zuid-Holland,182]  |
 | [Zeeland,39]|
 | [Friesland,65]  |
 +---+
 13 rows
 434 ms
 neo4j-sh (?)$ cypher 2.1.experimental match 
 (poi)-[:HAS_CHILD*0..]-(poif)-[:HAS_CHILD*0..1]-(poiq:Poi {name: 
 Netherlands})
  with poi,poif
  match 
 (period)-[:HAS_CHILD*0..]-(periodf)-[:HAS_CHILD*0..1]-(periodq:Period 
 {name: 2014-Q2})
  with poif,periodf,poi,period
  match (poi)-[hl:HAS_LOCATION]-(dp)-[hp:HAS_PERIOD]-(period)
  with *periodf*.name as fname ,count(distinct dp) as fcount
  return [fname,fcount] as facets;
 +--+
 | facets   |
 +--+
 | [2014-M05,352] |
 | [2014-M04,355] |
 | [2014-Q2,1089] |
 | [2014-M06,371] |
 +--+
 4 rows
 327 ms

 Please note we had the best results with the Cypher 2.1.experimental that 
 was announced here http://neo4j.com/blog/neo4j-2-1-graph-etl/ 

 My concrete question:

 Anyone has got an idea how to construct a cypher that returns counts for 
 both facets (and in fact n facets, since the real case uses 4 hierarchical 
 facets) ?






-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Retrieving a list of all properties of nodes having a specific label .. is it possible?

2014-06-27 Thread Tom Zeppenfeldt
Is there a way to retrieve from an existing db a list of properties that 
are linked to 1 or more nodes having a specific label?

So, if I've created 

(n:label1 {prop1: 'prop1value'})
(m:label1 {prop2 : 'prop2value'})

a call like

/db/data/labels/*label1*/properties 

would return 

[prop1,prop2] 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Parameters in statements through transactional HTTP endpoint?

2014-06-26 Thread Tom Zeppenfeldt
POSTing this :

{
  statements : [ {
statement : match(uc:usercase {name:{name}}) return uc,
params: {
  name : myname
},
resultDataContents : [ graph ]
  } ]
} 

to the transactional endpoint returns:

{
commit: http://mydomain.com:7474/db/data/transaction/106/commit;,
results: [
{
columns: [
uc
],
data: []
}
],
transaction: {
expires: Thu, 26 Jun 2014 08:39:16 +
},
errors: [
{
code: Neo.ClientError.Statement.ParameterMissing,
message: Expected a parameter named name
}
]
}
 

Is it me using a wrong syntax? If I would have several statements in a 
transaction, I would expect a structure that allowed a query and params as 
children of the statement. Or is it not possible to provide parameters 
using the transactional endpoint.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Parameters in statements through transactional HTTP endpoint?

2014-06-26 Thread Tom Zeppenfeldt
Ok. Thanks ! I assumed naming was similar to cypher endpoint. And as
always, assuming is not a good thing to do ;)


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-06-26 15:23 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 parameters
 Not
 params

 Sent from mobile device

 Am 26.06.2014 um 10:46 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 POSTing this :

 {
   statements : [ {
 statement : match(uc:usercase {name:{name}}) return uc,
 params: {
   name : myname
 },
 resultDataContents : [ graph ]
   } ]
 }

 to the transactional endpoint returns:

 {
 commit: http://mydomain.com:7474/db/data/transaction/106/commit;,
 results: [
 {
 columns: [
 uc
 ],
 data: []
 }
 ],
 transaction: {
 expires: Thu, 26 Jun 2014 08:39:16 +
 },
 errors: [
 {
 code: Neo.ClientError.Statement.ParameterMissing,
 message: Expected a parameter named name
 }
 ]
 }


 Is it me using a wrong syntax? If I would have several statements in a
 transaction, I would expect a structure that allowed a query and params as
 children of the statement. Or is it not possible to provide parameters
 using the transactional endpoint.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Multiple hierarchical facets continued

2014-06-25 Thread Tom Zeppenfeldt
Hi all,

Recently I worked with Michael Hunger on a typical faceted search case, but 
since we haven't found the holy grail yet, I'm also sharing our findings 
over here.

The dropboxlink 
https://www.dropbox.com/s/65rc2sz6p2lrpge/TomZepFacets.tar.gz contains a 
Neo4j 2.1.2 db with about 6000 random nodes, modeled as follows (the db 
also contains a :Meta model).  In terms of cardinality each :Datapoint has 
1 :HAS_LOCATION and 1 :HAS_PERIOD relationship
.[image: Inline afbeelding 1] 
https://mail.google.com/mail/u/0/?ui=2ik=cffa13707eview=attth=146c0088c0e62770attid=0.1disp=embrealattid=ii_146beff0f2f2d71dzwatsh=1



When requesting a filtered set of datapoints (with filters applied for a 
country and a period of time)  I succeeded in getting the counts for one of 
the facets, but not for both of them in a single cypher.

The current approach is as follows:
- retrieve all descendants of the filtervalue in the :Poi and  :Period 
hierarchies, including the filtervalue itself. This results in a set of 
nodes/leaves 
- match all  :Datapoint nodes with the descendants. 


neo4j-sh (?)$ cypher 2.1.experimental match 
(poi)-[:HAS_CHILD*0..]-(poif)-[:HAS_CHILD*0..1]-(poiq:Poi {name: 
Netherlands})
 with poi,poif
 match 
(period)-[:HAS_CHILD*0..]-(periodf)-[:HAS_CHILD*0..1]-(periodq:Period 
{name: 2014-Q2})
 with poif,periodf,poi,period
 match (poi)-[hl:HAS_LOCATION]-(dp)-[hp:HAS_PERIOD]-(period)
 with *poif*.name as fname ,count(distinct dp) as fcount
 return [fname,fcount] as facets;
+---+
| facets|
+---+
| [Overijssel,73] |
| [Drenthe,31]|
| [Utrecht,73]|
| [Gelderland,143]|
| [Flevoland,22]  |
| [Netherlands,1089]  |
| [Groningen,45]  |
| [Noord-Holland,128] |
| [Noord-Brabant,185] |
| [Limburg,103]   |
| [Zuid-Holland,182]  |
| [Zeeland,39]|
| [Friesland,65]  |
+---+
13 rows
434 ms
neo4j-sh (?)$ cypher 2.1.experimental match 
(poi)-[:HAS_CHILD*0..]-(poif)-[:HAS_CHILD*0..1]-(poiq:Poi {name: 
Netherlands})
 with poi,poif
 match 
(period)-[:HAS_CHILD*0..]-(periodf)-[:HAS_CHILD*0..1]-(periodq:Period 
{name: 2014-Q2})
 with poif,periodf,poi,period
 match (poi)-[hl:HAS_LOCATION]-(dp)-[hp:HAS_PERIOD]-(period)
 with *periodf*.name as fname ,count(distinct dp) as fcount
 return [fname,fcount] as facets;
+--+
| facets   |
+--+
| [2014-M05,352] |
| [2014-M04,355] |
| [2014-Q2,1089] |
| [2014-M06,371] |
+--+
4 rows
327 ms

Please note we had the best results with the Cypher 2.1.experimental that 
was announced here http://neo4j.com/blog/neo4j-2-1-graph-etl/ 

My concrete question:

Anyone has got an idea how to construct a cypher that returns counts for 
both facets (and in fact n facets, since the real case uses 4 hierarchical 
facets) ?




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Hierarchical facets

2014-06-17 Thread Tom Zeppenfeldt
Hi Michael,

have you been able to look at the profiling info that I sent you ? Perhaps
we can have a chat on it tomorrow in Amsterdam ..

Best,

Tom


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-05-21 21:23 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 That's why I suggested UNION.

 So the two individual queries take 14s? Still way too long.


 On Wed, May 21, 2014 at 3:40 PM, Tom Zeppenfeldt tomzeppenfe...@gmail.com
  wrote:

 I have some problems starting the shell from my Mac Terminal (it's giving
 me a out of mem error) , but form the webadmin powerconsole. Can't find any
 documentation either on how to set shell to have me return profile.

 neo4j-sh (?)$ export termname=Eurovoc

 *Your first Query*
 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10

  ;
 == +-+
 == | t.name  | count |
 == +-+
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == | rechtsvordering   | 915   |
 == +-+
 == 10 rows
 *== 8775 ms*

 *Your second Query*
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == SyntaxException: t not defined (line 1, column 79)
 == match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10
 ==
  ^
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t2.name, count(distinct j) as count  order by
 count desc limit 10;
 == +---+
 == | t2.name   | count |
 == +---+
 == | Eurovoc | 9576  |
 == +---+
 == 1 row
 *== 3668 ms*


 But what I need is to include the docs on both the term I request and the
 count on its children, like this. I notice that the combination takes
 longer than the two separate queries combined.

 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT*0..1]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == +-+
 == | t.name  | count |
 == +-+
 == | Eurovoc   | 9576  |
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == +-+
 == 10 rows
 *== 17802 ms*

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Relationships corrupted after upgrade to 2.1.1 ?

2014-06-01 Thread Tom Zeppenfeldt
After upgrading from 2.0.3. to 2.1.1 some of my cypher queries return 
errors on a specific node:

match (n)-[r]-(m) where id(n)=6620 return n

Unable to load one or more relationships from Node[6620]. This usually 
happens when relationships are deleted by someone else just as we are about 
to load them. Please try again.


When I run a larger query in which this specific node is traversed, I get 
(in *red *the failing relationship*)*


{
message: Unable to load one or more relationships from Node[6620]. This 
usually happens when relationships are deleted by someone else just as we 
are about to load them. Please try again.
exception: NotFoundException
fullname: org.neo4j.graphdb.NotFoundException
-stacktrace: [
org.neo4j.kernel.impl.core.NodeImpl.loadMoreRelationshipsFromNodeManager(NodeImpl.java:481)
org.neo4j.kernel.impl.core.NodeImpl.getMoreRelationships(NodeImpl.java:358)
org.neo4j.kernel.impl.core.NodeImpl.loadInitialRelationships(NodeImpl.java:288)
org.neo4j.kernel.impl.core.NodeImpl.ensureRelationshipMapNotNull(NodeImpl.java:260)
org.neo4j.kernel.impl.core.NodeImpl.getAllRelationshipsOfType(NodeImpl.java:181)
org.neo4j.kernel.impl.core.NodeImpl.getRelationships(NodeImpl.java:241)
org.neo4j.kernel.impl.api.store.PersistenceCache.nodeGetRelationships(PersistenceCache.java:200)
org.neo4j.kernel.impl.api.store.CacheLayer.nodeListRelationships(CacheLayer.java:452)
org.neo4j.kernel.impl.api.StateHandlingStatementOperations.nodeGetRelationships(StateHandlingStatementOperations.java:972)
org.neo4j.kernel.impl.api.ConstraintEnforcingEntityOperations.nodeGetRelationships(ConstraintEnforcingEntityOperations.java:358)
org.neo4j.kernel.impl.api.OperationsFacade.nodeGetRelationships(OperationsFacade.java:174)
org.neo4j.kernel.impl.core.NodeProxy.getRelationships(NodeProxy.java:170)
org.neo4j.kernel.impl.core.NodeProxy.getRelationships(NodeProxy.java:76)
org.neo4j.kernel.StandardExpander$RegularExpander.doExpand(StandardExpander.java:583)
org.neo4j.kernel.StandardExpander$RelationshipExpansion.iterator(StandardExpander.java:195)
org.neo4j.kernel.impl.traversal.TraversalBranchImpl.expandRelationshipsWithoutChecks(TraversalBranchImpl.java:115)
org.neo4j.kernel.impl.traversal.TraversalBranchImpl.expandRelationships(TraversalBranchImpl.java:104)
org.neo4j.kernel.impl.traversal.TraversalBranchImpl.initialize(TraversalBranchImpl.java:131)
org.neo4j.kernel.impl.traversal.TraversalBranchImpl.next(TraversalBranchImpl.java:151)
org.neo4j.kernel.impl.traversal.TraversalBranchWithState.next(TraversalBranchWithState.java:32)
org.neo4j.kernel.impl.traversal.StartNodeTraversalBranch.next(StartNodeTraversalBranch.java:50)
org.neo4j.graphdb.traversal.PreorderDepthFirstSelector.next(PreorderDepthFirstSelector.java:49)
org.neo4j.kernel.impl.traversal.MonoDirectionalTraverserIterator.fetchNextOrNull(MonoDirectionalTraverserIterator.java:68)
org.neo4j.kernel.impl.traversal.MonoDirectionalTraverserIterator.fetchNextOrNull(MonoDirectionalTraverserIterator.java:35)
org.neo4j.helpers.collection.PrefetchingIterator.peek(PrefetchingIterator.java:60)
org.neo4j.helpers.collection.PrefetchingIterator.hasNext(PrefetchingIterator.java:46)
scala.collection.convert.Wrappers$JIteratorWrapper.hasNext(Wrappers.scala:41)
scala.collection.Iterator$class.toStream(Iterator.scala:1143)
scala.collection.AbstractIterator.toStream(Iterator.scala:1157)
scala.collection.Iterator$$anonfun$toStream$1.apply(Iterator.scala:1143)
scala.collection.Iterator$$anonfun$toStream$1.apply(Iterator.scala:1143)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1085)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1077)
scala.collection.immutable.Stream$$anonfun$map$1.apply(Stream.scala:376)
scala.collection.immutable.Stream$$anonfun$map$1.apply(Stream.scala:376)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1085)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1077)
scala.collection.immutable.Stream$$anonfun$filteredTail$1.apply(Stream.scala:1149)
scala.collection.immutable.Stream$$anonfun$filteredTail$1.apply(Stream.scala:1149)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1085)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1077)
scala.collection.immutable.Stream$$anonfun$filteredTail$1.apply(Stream.scala:1149)
scala.collection.immutable.Stream$$anonfun$filteredTail$1.apply(Stream.scala:1149)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1085)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1077)
scala.collection.immutable.Stream$$anonfun$map$1.apply(Stream.scala:376)
scala.collection.immutable.Stream$$anonfun$map$1.apply(Stream.scala:376)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1085)
scala.collection.immutable.Stream$Cons.tail(Stream.scala:1077)
scala.collection.immutable.Stream.foldLeft(Stream.scala:563)
org.neo4j.cypher.internal.compiler.v2_1.pipes.matching.PatternMatcher.traverseRelationship(PatternMatcher.scala:163)

[Neo4j] Re: relations between group on nodes

2014-05-26 Thread Tom Zeppenfeldt
Assuming that you can identify the 100 nodes 

//  MATCH and/or filter the 100 nodes 
MATCH (n)
WHERE 

// put the nodes in a collection
WITH collect(n) AS mynodes

// get als the relations withing the context of the collection
MATCH (n)-[r]-(m)
WHERE (n IN mynodes) AND (m IN mynodes)

RETURN n,r,m

On Monday, 26 May 2014 09:15:45 UTC+2, natali wrote:

 hey'
 i have a db with 300,000,000 relations and 20,000,000 nodes 
 and i have a group of 100 nodes that i wanna find the relation between 
 this nodes and create from it a sub graph,
 how can i do it with java api? 
 (find path only works between 2 nodes)
 thank you.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Hierarchical facets

2014-05-22 Thread Tom Zeppenfeldt
yep, the two individual ones combined take about 12-13 secs . what does the
profiling tell you?


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-05-21 21:23 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 That's why I suggested UNION.

 So the two individual queries take 14s? Still way too long.


 On Wed, May 21, 2014 at 3:40 PM, Tom Zeppenfeldt tomzeppenfe...@gmail.com
  wrote:

 I have some problems starting the shell from my Mac Terminal (it's giving
 me a out of mem error) , but form the webadmin powerconsole. Can't find any
 documentation either on how to set shell to have me return profile.

 neo4j-sh (?)$ export termname=Eurovoc

 *Your first Query*
 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10

  ;
 == +-+
 == | t.name  | count |
 == +-+
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == | rechtsvordering   | 915   |
 == +-+
 == 10 rows
 *== 8775 ms*

 *Your second Query*
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == SyntaxException: t not defined (line 1, column 79)
 == match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10
 ==
  ^
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t2.name, count(distinct j) as count  order by
 count desc limit 10;
 == +---+
 == | t2.name   | count |
 == +---+
 == | Eurovoc | 9576  |
 == +---+
 == 1 row
 *== 3668 ms*


 But what I need is to include the docs on both the term I request and the
 count on its children, like this. I notice that the combination takes
 longer than the two separate queries combined.

 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT*0..1]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == +-+
 == | t.name  | count |
 == +-+
 == | Eurovoc   | 9576  |
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == +-+
 == 10 rows
 *== 17802 ms*

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Hierarchical facets

2014-05-21 Thread Tom Zeppenfeldt
Hi, after publishing this 
graphgist http://gist.neo4j.org/?05d92f567adbe971afc5 , Michael suggested 
to change the pattern and providing a profile.

This is the result:

The query is

{
  query : match 
(j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT*0..1]-(t2:term 
{name:{termname}}) return t.name, count(distinct j) as count order by count 
desc limit 10,
params:
{termname : Eurovoc}
} 


and mydomain:7474/db/data/cypher?profile=true returns after 15 secs  (the 
pattern with (j:jurt)-[:HAS_TERM|BT*0..]-(t:term)  took 20 sec)

{
columns: [
t.name,
count
],
data: [
[
Eurovoc,
9576
],
[
gezondheidsbeleid,
1823
],
[
overtreding,
1393
],
[
Europese organisatie,
1389
],
[
EU-instantie,
1323
],
[
mondiale organisatie,
1277
],
[
gespecialiseerde instelling van de VN,
1143
],
[
handeling van de EU,
1129
],
[
internationaal publiekrecht,
1091
],
[
sociaal beleid,
971
]
],
plan: {
args: {
returnItemNames: [
t.name,
count
],
_rows: 10,
_db_hits: 0,
symKeys: [
t.name,
  INTERNAL_AGGREGATE8f87b8f0-a925-43fd-aa9b-2319f9efee52
]
},
dbHits: 0,
name: ColumnFilter,
children: [
{
args: {
limit: Literal(10),
orderBy: [
SortItem(Cached( 
 INTERNAL_AGGREGATE8f87b8f0-a925-43fd-aa9b-2319f9efee52 of type 
Integer),false)
],
_rows: 10,
_db_hits: 0
},
dbHits: 0,
name: Top,
children: [
{
args: {
keys: [
Cached(t.name of type Any)
],
_rows: 5276,
aggregates: [
( 
 INTERNAL_AGGREGATE8f87b8f0-a925-43fd-aa9b-2319f9efee52,Distinct(Count(j),j))
],
_db_hits: 0
},
dbHits: 0,
name: EagerAggregation,
children: [
{
args: {
_rows: 877826,
_db_hits: 877826,
exprKeys: [
t.name
],
symKeys: [
  UNNAMED30,
j,
t,
  UNNAMED14,
  UNNAMED50,
t2,
  UNNAMED29
]
},
dbHits: 877826,
name: Extract,
children: [
{
args: {
_rows: 877826,
_db_hits: 0,
pred: hasLabel(j:jurt(1))
},
dbHits: 0,
name: Filter,
children: [
{
args: {
g: (j)-[' 
 UNNAMED14']-(  UNNAMED29),(  UNNAMED29)-['  UNNAMED30']-(t),
_rows: 877826,
_db_hits: 877850
},
dbHits: 877850,
name: PatternMatcher,
children: [
{
args: {
_rows: 8466,
_db_hits: 0,
 

Re: [Neo4j] Hierarchical facets

2014-05-21 Thread Tom Zeppenfeldt
I have some problems starting the shell from my Mac Terminal (it's giving 
me a out of mem error) , but form the webadmin powerconsole. Can't find any 
documentation either on how to set shell to have me return profile.

neo4j-sh (?)$ export termname=Eurovoc

*Your first Query*
neo4j-sh (?)$ match 
(j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT]-(t2:term 
{name:{termname}})  return t.name, count(distinct j) as count  order by 
count desc limit 10

 ;
== +-+
== | t.name  | count |
== +-+
== | gezondheidsbeleid | 1823  |
== | overtreding   | 1393  |
== | Europese organisatie  | 1389  |
== | EU-instantie  | 1323  |
== | mondiale organisatie  | 1277  |
== | gespecialiseerde instelling van de VN | 1143  |
== | handeling van de EU   | 1129  |
== | internationaal publiekrecht   | 1091  |
== | sociaal beleid| 971   |
== | rechtsvordering   | 915   |
== +-+
== 10 rows
*== 8775 ms*

*Your second Query*
neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term 
{name:{termname}})  return t.name, count(distinct j) as count  order by 
count desc limit 10;
== SyntaxException: t not defined (line 1, column 79)
== match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term {name:{termname}}) 
 return t.name, count(distinct j) as count  order by count desc limit 10
== 
   ^
neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term 
{name:{termname}})  return t2.name, count(distinct j) as count  order by 
count desc limit 10;
== +---+
== | t2.name   | count |
== +---+
== | Eurovoc | 9576  |
== +---+
== 1 row
*== 3668 ms*


But what I need is to include the docs on both the term I request and the 
count on its children, like this. I notice that the combination takes 
longer than the two separate queries combined.

neo4j-sh (?)$ match 
(j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT*0..1]-(t2:term 
{name:{termname}})  return t.name, count(distinct j) as count  order by 
count desc limit 10;
== +-+
== | t.name  | count |
== +-+
== | Eurovoc   | 9576  |
== | gezondheidsbeleid | 1823  |
== | overtreding   | 1393  |
== | Europese organisatie  | 1389  |
== | EU-instantie  | 1323  |
== | mondiale organisatie  | 1277  |
== | gespecialiseerde instelling van de VN | 1143  |
== | handeling van de EU   | 1129  |
== | internationaal publiekrecht   | 1091  |
== | sociaal beleid| 971   |
== +-+
== 10 rows
*== 17802 ms*

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Hierarchical facets

2014-05-21 Thread Tom Zeppenfeldt
yeah.. found that out too ..  profiled things are already in groups.


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-05-21 16:36 GMT+02:00 Michael Hunger michael.hun...@neotechnology.com
:

 Prefix your query with profile 

 Sent from mobile device

 Am 21.05.2014 um 15:40 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 I have some problems starting the shell from my Mac Terminal (it's giving
 me a out of mem error) , but form the webadmin powerconsole. Can't find any
 documentation either on how to set shell to have me return profile.

 neo4j-sh (?)$ export termname=Eurovoc

 *Your first Query*
 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10

  ;
 == +-+
 == | t.name  | count |
 == +-+
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == | rechtsvordering   | 915   |
 == +-+
 == 10 rows
 *== 8775 ms*

 *Your second Query*
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == SyntaxException: t not defined (line 1, column 79)
 == match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term {name:{termname}})
  return t.name, count(distinct j) as count  order by count desc limit 10
 ==
  ^
 neo4j-sh (?)$ match (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t2:term
 {name:{termname}})  return t2.name, count(distinct j) as count  order by
 count desc limit 10;
 == +---+
 == | t2.name   | count |
 == +---+
 == | Eurovoc | 9576  |
 == +---+
 == 1 row
 *== 3668 ms*


 But what I need is to include the docs on both the term I request and the
 count on its children, like this. I notice that the combination takes
 longer than the two separate queries combined.

 neo4j-sh (?)$ match
 (j:jurt)-[:HAS_TERM]-()-[:BT*0..]-(t:term)-[:BT*0..1]-(t2:term
 {name:{termname}})  return t.name, count(distinct j) as count  order by
 count desc limit 10;
 == +-+
 == | t.name  | count |
 == +-+
 == | Eurovoc   | 9576  |
 == | gezondheidsbeleid | 1823  |
 == | overtreding   | 1393  |
 == | Europese organisatie  | 1389  |
 == | EU-instantie  | 1323  |
 == | mondiale organisatie  | 1277  |
 == | gespecialiseerde instelling van de VN | 1143  |
 == | handeling van de EU   | 1129  |
 == | internationaal publiekrecht   | 1091  |
 == | sociaal beleid| 971   |
 == +-+
 == 10 rows
 *== 17802 ms*

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: Cartesian product in Neo4j

2014-05-02 Thread Tom Zeppenfeldt
Assuming that you have nodes representing suit en value, all cards can be 
created like this.

match (s:suit),(v:value)
with s,v
create (s)-[:SUIT]-(c:CARD)-[:VALUE]-(v)

Best, Tom

On Friday, 2 May 2014 22:33:15 UTC+2, Gabriel Peschl wrote:

 Hi everyone,

 I would like know how I can perform a cartesian product in 2 graph, stored 
 in neo4j.

 For example:

 the first graph I have this nodes: 
 Ace
 King
 Jack

 in the second graph, I have this nodes:
 Hearts
 Diamonds
 Clubs

 So, the result after the cartesian product:
 First node: (Ace, Hearts)
 Second node: (Ace, Diamonds)
 Third node: (Ace, Clubs)
  and so on

 Thank you very much!



-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: Bug in cypher when filtering collection ?

2014-04-19 Thread Tom Zeppenfeldt
Hi Lundin,

Thanks a lot for your replies and efforts to find a workaround. I finally 
decided to use the explicit typecasting, and build the rest of the cypher 
statement which now looks as this:

MATCH (p:project {name: 
ProjA})-[:CURRENT|PREV*]-(pv:projversion)-[pu:ADD|REMOVE]-(pt:projtransition)-[:HASALIAS]-(tt:transition)
 
WHERE pv.version = 1 
WITH tt,pv,type(pu) AS putype  ORDER BY tt.id,pv.version DESC 
WITH tt,HEAD(collect(putype)) AS lastputype WHERE lastputype = ADD
MATCH (tt)-[tu:ADD|REMOVE]-(tv:tocversion) 
WITH tt,tu,tv ORDER BY tt.id,tv.version DESC
WITH tt,COLLECT([type(tu),tv.version]) AS tus
WITH tt, HEAD([x IN tus WHERE str(x[1])=str(4) | [x[0],x[1]]]) AS 
lastupdate WHERE lastupdate[0]  ADD
RETURN tt.id as conflicting

Which returns nodes that are conflicting (i.e. were not yet created or were 
already deleted) in specific versions of two different networks.
Do you agree with me that this typecasting should not be necessary and that 
cypher internally does some weird things that prevents comparing of integer 
values ?

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: Any pros/cons between relationship vs. relationship node?

2014-04-18 Thread Tom Zeppenfeldt
Pros
- you can use the intermediate nodes to link other nodes to, instead of 
providing nodeids as values of relationship properties
- it allows you to create a system to  version networks

Cons
- longer paths, more complex queries
- managing the rels between the principal nodes is more complex, what is a 
rel in  normal setup, is now a rel-intermediatenode-rel construct
- if you want to make vizualisations, it may be necessary to skip the 
intermediate nodes, since force-based lay-out algorithms will be disturbed 
by the intermediate nodes.


On Friday, 18 April 2014 08:47:17 UTC+2, Aseem Kishore wrote:

 Example: users following other users.

 Is there any advantage/disadvantage to directly connecting users with 
 relationships, vs. indirectly connecting them via nodes?

 E.g.

 (:User) -[:FOLLOWS]- (:User)

 vs.

 (:User) -[:SOURCE_USER]- (:Follow) -[:TARGET_USER]- (:User)

 The node obviously lends more flexibility (e.g. others can like it, it 
 can be placed in a linked list, etc.), but I'm wondering: are there any 
 downsides to it? E.g. if I commonly want to fetch a user's followers, is 
 the extra hop a significant performance drain? (I can test performance, but 
 I guess I'm wondering if there are other factors I can't even think of.)

 Thanks!

 Aseem



-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: Bug in cypher when filtering collection ?

2014-04-18 Thread Tom Zeppenfeldt
created console here http://console.neo4j.org/?id=s0kf37

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Re: Any pros/cons between relationship vs. relationship node?

2014-04-18 Thread Tom Zeppenfeldt
I guess having both unnecessarily complicates the model. I'd get rid of the 
direct one, since apparently you need the intermediate node. You can always 
recreate it on the basis of the rels through the intermediate node.  
And eh... may I kindly suggest to rethink the title of your next post  ;) ? 

Tom
 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Issues creating a gist (//graph keeps displaying results of first query)

2014-03-25 Thread Tom Zeppenfeldt
I have created a gist at http://gist.neo4j.org/?9758285  but the //graph 
 tag doesn't seem to display the graph corresponding to the last query. 
//table  seems to work fine. 
What am I doing wrong  ? 


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Issues creating a gist (//graph keeps displaying results of first query)

2014-03-25 Thread Tom Zeppenfeldt


 Thanks for pointing it out. Should have read it more carefully. Indeed too 
 bad that filtering doesn't apply to  graphs. 



Besides, when running a cypher in the console  I included in the gist , 
like  

match (n) return id(n)

it returns 0 rows, which is weird too.

 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Issues creating a gist (//graph keeps displaying results of first query)

2014-03-25 Thread Tom Zeppenfeldt


 Thanks for the feedback and looking forward to //graph returning 
 highlighted results.   .. And to further improving my own gisting skills 
 (this was my first) 


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: find difference between 2 collection of paths

2014-03-23 Thread Tom Zeppenfeldt


 as an idea  , not tested..


match p=(n)-[:REL1*]-(m) 
where NOT n-[:REL2*]-m
return n,m  

or return  p  

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Re: find difference between 2 collection of paths

2014-03-23 Thread Tom Zeppenfeldt
hard to say without any idea about the far more complex stuff you're trying
to achieve, and the comparisons you'd like to do ..

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] first time a query is run it produces different results in 2.1.0-M01

2014-03-19 Thread Tom Zeppenfeldt
Hi Mattias, thanks for the update. We are really struggling with this one, 
because we are at a performance with Neo4j at about 4 sec and a comparable 
query in a MariaDB SQL instance of 0.17 sec.

On Wednesday, 19 March 2014 14:32:28 UTC+1, Mattias Persson wrote:

 This issue has been fixed and will be included in the next milestone.

 2014-03-08 19:29 GMT+01:00 Tom Zeppenfeldt tomzepp...@gmail.comjavascript:
 :

 And yes.. it happens with other queries as well .. 

 and query times are a lot longer then expected with a db of this size, 
 although I indexed the crucial parts.

 neo4j-sh (?)$ schema

 Indexes
   ON :Person(id)ONLINE (for uniqueness constraint) 
   ON :Term(id)  ONLINE 
   ON :instantie(id) ONLINE 
   ON :jurt(jurt_id) ONLINE 
   ON :rechter(id)   ONLINE 

 Constraints
   ON (person:Person) ASSERT person.id IS UNIQUE

 On Saturday, 8 March 2014 18:34:17 UTC+1, Michael Hunger wrote:

 Hi Tom,

 does this happen with any database? I.e. imported by your load-csv 
 script?

 I asked my colleagues to look into it. Perhaps related to some changes 
 in the relationship-store in Neo4j 2.1

 Do you see similar behavior also for other queries?

  Cheers,

 Michael

 
 (michael http://twitter.com/mesirii}-[:SUPPORTS]-(*YOU*)-[:USE]-(
 Neo4j http://neo4j.org)
 Learn Online http://neo4j.org/learn/online_course, 
 Offlinehttp://www.neo4j.org/events or 
 Read a Book http://graphdatabases.com (in Deutschhttp://bit.ly/das-buch
 )
 We're trading T-shirts for cool GraphGist Modelshttp://bit.ly/graphgist




  
 Am 07.03.2014 um 23:02 schrieb Tom Zeppenfeldt tomzepp...@gmail.com:

 I have a graph db with about 1 docs  (:jurt)  and about 12000 terms 
 (t:Term) from a vocabulary. There are about 1.2M relationships of type 
  (j:jurt)-[:HAS_TERM]-(t:Term)

 To find out which documents are similar to a given document, based on a 
 count of common terms, I use this query

 match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt)
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J75312'
 with j1,j2,count(t) as commonterms
 return j1.jurt_id,j2.jurt_id,commonterms
 order by commonterms desc
 limit 3

 What I notice is that the first time the query is run, the results are 
 different from the next times... from the second time onwards, the results 
 are the same. In between, there are no other processes running..  
 Whether I run the queries from the browser, the shell or the REST API, 
 they all show the same phenomenon.

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by 
 commonterms desc limit 3;  

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 226 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 215 |

 +---+

 3 rows

 6288 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by 
 commonterms desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6299 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by 
 commonterms desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6354 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by 
 commonterms desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6108 ms


 What may cause this  ? 

 -- 
 You received this message because you are subscribed to the Google 
 Groups Neo4j group.
 To unsubscribe from this group and stop receiving

Re: [Neo4j] Tuning/ performance / predictability

2014-03-19 Thread Tom Zeppenfeldt
Michael, are there any new insights on this ?  We are still at 4 seconds to 
do this on Neo4j 2.0.1 against 0.17 secs on a MariaDB instance with a 
comparable query.

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-14 Thread Tom Zeppenfeldt
no problem Michael. It takes long for each query. changing memconfig didn't
make a lot of difference . Also talking with the structr.org guys  about
it..

Best, Tom


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-03-14 15:15 GMT+01:00 Michael Hunger michael.hun...@neopersistence.com
:

 First run or subsequent one?

 And do you run this shell against server or standalone with memory config
 changed?

 I mean it has to pull through 500.000 paths, group them by j2 and sort
 them into the size 3 top-window. But still it shouldn't take that long.

 Still investingating, sorry.

 Am 10.03.2014 um 13:40 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 no problem .. I figured out that I had to use the terms and the 1.2M went
 in  under 2 minutes :)

 now back to our query

 match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2)
 where j1.jurt_id = 'J7' AND j2  j1
 RETURN j2,count(*) as commonterms
 order by commonterms desc
 limit 3;

 still over 4 secs

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2)

  where j1.jurt_id = 'J7' AND j2  j1

  RETURN j2.jurt_id,count(*) as commonterms

  order by commonterms desc

  limit 3;

 +--+

 | j2.jurt_id | commonterms |

 +--+

 | J72191   | 68  |

 | J73483   | 67  |

 | J72923   | 66  |

 +--+

 3 rows

 4358 ms

 neo4j-sh (?)$


 I also tried to follow this
 http://stackoverflow.com/questions/18192774/how-to-change-the-memory-config-for-the-neo4j-shell-command-tool-of-cypher-batchbut
  not sure whether it has any effect.
 However, you talking about editing bin/neo4j-shell, makes me doubt whether
 I'm doing the right thing. sorry, I'm on a steep learning curve here  :) .
 Are you meaning to edit this section  ?

 exec $JAVACMD $JAVA_OPTS \

   $EXTRA_JVM_ARGUMENTS \

   -classpath $CLASSPATH \

   -Dapp.name=neo4j-shell \

   -Dapp.pid=$$ \

   -Dapp.repo=$REPO \

   -Dbasedir=$BASEDIR \

   -Dfile.encoding=UTF-8 \

   org.neo4j.shell.StartClient \

   $@





 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-11 Thread Tom Zeppenfeldt
Hi Michael,

could you perhaps share your neo4j-shell for me to learn from. I'm still 
very far away from the 1.6 secs that you were able to achieve.

Best,

Tom

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-10 Thread Tom Zeppenfeldt
Hi Michael,

Thanks for your reply. Basically you suggest not to overspecify the 
queries, by leaving out the  labels or identifiers when not necessary. And 
I learned my lesson with regard to using snapshots :)

BTW :  Assuming that you are using the db that I shared with you and 
converted it to a 2.0.1. version, I appreciated the increased speed, but 
does it also explain why the returned counts are different ? 

If you have converted the db, could you share the datastore (the 2.0.1. 
one) back to me ? 

Thanks a lot !

Best,  Tom 

On Monday, 10 March 2014 07:11:00 UTC+1, Michael Hunger wrote:

 Hi Tom,

 with 2.0.1 the query time went down to 1.6 seconds.
 It still has to pull through and aggregate 500.000 rels but should 
 actually be faster doing this.

 match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2) 
 where j1.jurt_id = 'J7' AND j2  j1
 RETURN j2,count(*) as commonterms 
 order by commonterms desc 
 limit 3;

 +-+
 | j2| commonterms |
 +-+
 | Node[19946]{jurt_id:J72191} | 68  |
 | Node[20977]{jurt_id:J73483} | 67  |
 | Node[21658]{jurt_id:J74261} | 64  |
 +-+
 3 rows
 1614 ms

 Cheers,

 Michael

 
 (michael 
 http://twitter.com/mesirii}-[:SUPPORTS]-(*YOU*)-[:USE]-(Neo4jhttp://neo4j.org
 )
 Learn Online http://neo4j.org/learn/online_course, 
 Offlinehttp://www.neo4j.org/events or 
 Read a Book http://graphdatabases.com (in Deutschhttp://bit.ly/das-buch
 )
 We're trading T-shirts for cool GraphGist Models http://bit.ly/graphgist




  
 Am 09.03.2014 um 20:00 schrieb Michael Hunger 
 michael...@neopersistence.com javascript::

 Ouch

 Share via dropbox

 You can share the 2.1 store with me or the loadcsv script with your csv 
 files

 Thanks for all the great feedback btw

 Can you send me your postal address and t-shirt size?

 Thx

 Sent from mobile device

 Am 09.03.2014 um 19:08 schrieb Tom Zeppenfeldt 
 t.zepp...@ophileon.comjavascript:
 :

 Ok Michael,

 - Just a question that may sound stupid :  What's  the best way to share 
 things privately over here ? Not seeing any clear option to do so.
 - I'll try to setup a server with 2.0.1 and try to use the 
 shell-import-tools. FYI : uploading the 1.2M rels uring LOAD CSV took over 
 24 hrs ...  hope your shell-import-tools work faster ..
  
 Best,

 Tom


 Met vriendelijke groet / With kind regards



 Ir. T. Zeppenfeldt
 van der Waalsstraat 30
 6706 JR  Wageningen
 The Netherlands

 Mobile: +31 6 23 28 78 06
 Phone: +31 3 17 84 22 17
 E-mail: t.zepp...@ophileon.com javascript:
  javascript:Web: www.ophileon.com
 Twitter: tomzeppenfeldt
 Skype: tomzeppenfeldt


 2014-03-09 16:27 GMT+01:00 Michael Hunger 
 michael...@neopersistence.comjavascript:
 :

 Could you send me the profike output from the shell? Easier to read on 
 mobile and also share the db with me privately

 Can you also try the query in 2.0.1?

 You can import the data using my shell-import-tools

 Or just generate textual cypher statements from load-csv

 Sent from mobile device

 Am 09.03.2014 um 16:11 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 query is executed as follows, in which I spot:

 _rows : 478380,
 _db_hits : 956760,

 which is actually higher (= worse ??)  than the original .. 

 {
   columns : [ j1.jurt_id, j2.jurt_id, commonterms ],
   data : [ [ J7, J72191, 68 ], [ J7, J73483, 67 ], [ 
 J7, J75683, 66 ] ],
   plan : {
 args : {
   returnItemNames : [ j1.jurt_id, j2.jurt_id, commonterms ],
   _rows : 3,
   _db_hits : 0,
   symKeys : [ j1.jurt_id, j2.jurt_id,  
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 ]
 },
 dbHits : 0,
 name : ColumnFilter,
 children : [ {
   args : {
 limit : Literal(3),
 orderBy : [ SortItem(Cached( 
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 of type 
 Integer),false) ],
 _rows : 3,
 _db_hits : 0
   },
   dbHits : 0,
   name : Top,
   children : [ {
 args : {
   keys : [ Cached(j1.jurt_id of type Any), Cached(j2.jurt_id 
 of type Any) ],
   _rows : 9992,
   aggregates : [ ( 
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372,Count(t)) ],
   _db_hits : 0
 },
 dbHits : 0,
 name : EagerAggregation,
 children : [ {
   args : {
 _rows : 478380,
 _db_hits : 956760,
 exprKeys : [ j1.jurt_id, j2.jurt_id ],
 symKeys : [ j1, t,   UNNAMED79, j2,   UNNAMED62 ]
   },
   dbHits : 956760,
   name : Extract,
   children : [ {
 args : {
   _rows : 478380,
   _db_hits : 0,
   pred : NOT(j2 == j1)
 },
 dbHits : 0,
 name : Filter,
 children

Re: [Neo4j] Tuning/ performance / predictability

2014-03-10 Thread Tom Zeppenfeldt
 

Hi Michael,

explanation. doing import-cypher now. just wondering whether (on the 8 GB 
machine with specs at start of this thread, except for now working with 
Neo4j 2.0.1) performance for creating rels as below is normal.  Creating 
nodes is fast, but when i'm creating 1.2M rels I'm looking at 1200 mins ?

neo4j-sh (?)$ import-cypher -i bt.csv match (n),(m) where n.id = {start} 
and m.id={end}  create (n)-[:BT]-(m)   

Query: match (n),(m) where n.id = {start} and m.id={end}  create 
(n)-[:BT]-(m) infile bt.csv delim ',' quoted false outfile (none) 
batch-size 1000

commit after 1000 row(s)  0. 12%: nodes = 0 rels = 1000 properties = 0 time 
55684 ms total 55684 ms

commit after 2000 row(s)  1. 24%: nodes = 0 rels = 2000 properties = 0 time 
53724 ms total 109408 ms

commit after 3000 row(s)  2. 36%: nodes = 0 rels = 3000 properties = 0 time 
56033 ms total 165441 ms

commit after 4000 row(s)  3. 42%: nodes = 0 rels = 4000 properties = 0 time 
54584 ms total 220025 ms

commit after 5000 row(s)  4. 54%: nodes = 0 rels = 5000 properties = 0 time 
55677 ms total 275702 ms

commit after 6000 row(s)  5. 67%: nodes = 0 rels = 6000 properties = 0 time 
53673 ms total 329375 ms

commit after 7000 row(s)  6. 73%: nodes = 0 rels = 7000 properties = 0 time 
54792 ms total 384167 ms

commit after 8000 row(s)  7. 85%: nodes = 0 rels = 8000 properties = 0 time 
56940 ms total 441107 ms

commit after 9000 row(s)  8. 97%: nodes = 0 rels = 9000 properties = 0 time 
54738 ms total 495845 ms

finish after 9597 row(s)  9. 99%: nodes = 0 rels = 9597 properties = 0 time 
34251 ms total 530096 ms

Import statement execution created 0 rows of output.

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-10 Thread Tom Zeppenfeldt

perhaps needless to say that indexes are set

Indexes

  ON :domain(id)ONLINE  

  ON :instantie(id) ONLINE  

  ON :jurt(jurt_id) ONLINE  

  ON :rechter(id)   ONLINE  

  ON :term(id)  ONLINE  


No constraints

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-10 Thread Tom Zeppenfeldt
no problem .. I figured out that I had to use the terms and the 1.2M went 
in  under 2 minutes :)

now back to our query

match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2) 
where j1.jurt_id = 'J7' AND j2  j1
RETURN j2,count(*) as commonterms 
order by commonterms desc 
limit 3;

still over 4 secs 

neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2) 

 where j1.jurt_id = 'J7' AND j2  j1   

 RETURN j2.jurt_id,count(*) as commonterms  

 order by commonterms desc  

 limit 3;   

+--+

| j2.jurt_id | commonterms |

+--+

| J72191   | 68  |

| J73483   | 67  |

| J72923   | 66  |

+--+

3 rows

4358 ms

neo4j-sh (?)$ 


I also tried to follow 
this 
http://stackoverflow.com/questions/18192774/how-to-change-the-memory-config-for-the-neo4j-shell-command-tool-of-cypher-batch
 
but not sure whether it has any effect. 
However, you talking about editing bin/neo4j-shell, makes me doubt whether 
I'm doing the right thing. sorry, I'm on a steep learning curve here  :) . 
Are you meaning to edit this section  ?

exec $JAVACMD $JAVA_OPTS \

  $EXTRA_JVM_ARGUMENTS \

  -classpath $CLASSPATH \

  -Dapp.name=neo4j-shell \

  -Dapp.pid=$$ \

  -Dapp.repo=$REPO \

  -Dbasedir=$BASEDIR \

  -Dfile.encoding=UTF-8 \

  org.neo4j.shell.StartClient \

  $@




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
I'm already stuck for a couple of days with a performance problem, or even 
queries that do not produce predictable results. I posted this one before, 
but now, after upgrading the machine from 2 to 8GB (hoping it was a lack of 
memory issue) , I don't know how to solve this. 

*Environment  : *
Cloudserver with : 8GB Ram 40GB SSD Disk Ubuntu 13.10 x64
Version : Neo4j 2.1.0-M01

*Settings adapted from defaults*
in neo4j-wrapper.conf
wrapper.java.initmemory=4096
wrapper.java.maxmemory=4096

in neo4j.properties
neostore.nodestore.db.mapped_memory=50M
neostore.relationshipstore.db.mapped_memory=100M
neostore.propertystore.db.mapped_memory=180M
neostore.propertystore.db.strings.mapped_memory=260M
neostore.propertystore.db.arrays.mapped_memory=260M

*Server info:*
HeapMemoryUsage
committed 4260102144
init 4294967296
max 4260102144
used 302304640

NonHeapMemoryUsage
committed 64909312
init 24313856
max 136314880
used 54561464

*Size of database*
Primitive count
NumberOfRelationshipIdsInUse 1294128
NumberOfNodeIdsInUse 55746
NumberOfPropertyIdsInUse 55036
NumberOfRelationshipTypeIdsInUse 11

*Model*

about 10k :jurt  (= some kind of document) nodes and 12k :Term nodes, with 
about 1.2M (jurt)-[:HAS_TERM]-(term) rels

*Use*

Find similar jurts based on number of common terms, like this:

match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt)
where NOT j1=j2 AND j1.jurt_id = {jurtid}
with j1,j2,count(t) as commonterms
return j1.jurt_id,j2.jurt_id,commonterms
order by commonterms desc
limit 3

the query above takes  5-6 secs, way too long I guess.  

*Query plan*

{
  columns : [ j1.jurt_id, j2.jurt_id, commonterms ],
  data : [ [ J7, J72191, 68 ], [ J7, J73483, 67 ], [ 
J7, J72924, 66 ] ],
  plan : {
args : {
  returnItemNames : [ j1.jurt_id, j2.jurt_id, commonterms ],
  _rows : 3,
  _db_hits : 0,
  symKeys : [ j1, j2.jurt_id, j1.jurt_id, commonterms, j2 ]
},
dbHits : 0,
name : ColumnFilter,
children : [ {
  args : {
limit : Literal(3),
orderBy : [ SortItem(commonterms,false) ],
_rows : 3,
_db_hits : 0
  },
  dbHits : 0,
  name : Top,
  children : [ {
args : {
  _rows : 9992,
  _db_hits : 19984,
  exprKeys : [ j1.jurt_id, j2.jurt_id ],
  symKeys : [ j1, j2, commonterms ]
},
dbHits : 19984,
name : Extract,
children : [ {
  args : {
returnItemNames : [ j1, j2, commonterms ],
_rows : 9992,
_db_hits : 0,
symKeys : [ j1, j2,  
 INTERNAL_AGGREGATE8b273443-699b-4262-8a48-41d7a316fa44 ]
  },
  dbHits : 0,
  name : ColumnFilter,
  children : [ {
args : {
  keys : [ j1, j2 ],
  _rows : 9992,
  aggregates : [ ( 
 INTERNAL_AGGREGATE8b273443-699b-4262-8a48-41d7a316fa44,Count(t)) ],
  _db_hits : 0
},
dbHits : 0,
name : EagerAggregation,
children : [ {
  args : {
_rows : 478380,
_db_hits : 0,
pred : (NOT(j1 == j2) AND hasLabel(j2:jurt(3)))
  },
  dbHits : 0,
  name : Filter,
  children : [ {
args : {
  start : {
identifiers : [ j1 ],
query : {jurtid},
producer : SchemaIndex,
property : jurt_id,
label : jurt
  },
  trail : (j1)-[  UNNAMED15:HAS_TERM WHERE 
(hasLabel(NodeIdentifier():Term(1)) AND hasLabel(NodeIdentifier():Term(1))) 
AND true]-(t)-[  UNNAMED37:HAS_TERM WHERE 
hasLabel(NodeIdentifier():jurt(3)) AND true]-(j2),
  _rows : 478380,
  _db_hits : 478518
},
dbHits : 478518,
name : TraversalMatcher,
children : [ ],
rows : 478380
  } ],
  rows : 478380
} ],
rows : 9992
  } ],
  rows : 9992
} ],
rows : 9992
  } ],
  rows : 3
} ],
rows : 3
  }
}



Every time I change the value of the  {jurtid}  param, the first run of the 
query returns different results then the subsequent runs

When I provide two params, like this:

match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
where NOT j1=j2 AND ((j1.jurt_id = {id1}) OR (j1.jurt_id = {id2})) 
with j1,j2,count(t) as commonterms 
return j1.jurt_id,j2.jurt_id,commonterms 
order by commonterms desc limit 3

it doesn't even return anything in the shell in the browser I get an 
Unknown error


-- 
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+unsubscr...@googlegroups.com.
For more options, visit 

Re: [Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
Hi Michael, thanks for your apparently not so lazy Sunday feed-back. I'm 
aware that it's not production-fähig. We're using this sandbox it hoping to 
demo what Neo4j is capable of  :S 

Tried the suggested query. No luck however. This is what I got (in over 6 
secs) . And yes i had an index on :jurt(jurt_id)

neo4j-sh (?)$ schema

Indexes

  ON :Person(id)ONLINE (for uniqueness constraint) 

  ON :Term(id)  ONLINE 

  ON :instantie(id) ONLINE 

  ON :jurt(jurt_id) ONLINE 

  ON :rechter(id)   ONLINE 


Constraints

  ON (person:Person) ASSERT person.id IS UNIQUE

neo4j-sh (?)$ export jurtid=J7

neo4j-sh (?)$ match (j1:jurt)

 where j1.jurt_id = {jurtid}

 with j1

 match (j1)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2)

 where j2  j1

 return j1.jurt_id,j2.jurt_id, count(t) as commonterms

 order by commonterms desc

 limit 3;

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J7   | J72191   | 68  |

| J7   | J73483   | 67  |

| J7   | J75683   | 66  |

+---+

3 rows

6320 ms


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
query is executed as follows, in which I spot:

_rows : 478380,
_db_hits : 956760,

which is actually higher (= worse ??)  than the original .. 

{
  columns : [ j1.jurt_id, j2.jurt_id, commonterms ],
  data : [ [ J7, J72191, 68 ], [ J7, J73483, 67 ], [ 
J7, J75683, 66 ] ],
  plan : {
args : {
  returnItemNames : [ j1.jurt_id, j2.jurt_id, commonterms ],
  _rows : 3,
  _db_hits : 0,
  symKeys : [ j1.jurt_id, j2.jurt_id,  
 INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 ]
},
dbHits : 0,
name : ColumnFilter,
children : [ {
  args : {
limit : Literal(3),
orderBy : [ SortItem(Cached( 
 INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 of type 
Integer),false) ],
_rows : 3,
_db_hits : 0
  },
  dbHits : 0,
  name : Top,
  children : [ {
args : {
  keys : [ Cached(j1.jurt_id of type Any), Cached(j2.jurt_id 
of type Any) ],
  _rows : 9992,
  aggregates : [ ( 
 INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372,Count(t)) ],
  _db_hits : 0
},
dbHits : 0,
name : EagerAggregation,
children : [ {
  args : {
_rows : 478380,
_db_hits : 956760,
exprKeys : [ j1.jurt_id, j2.jurt_id ],
symKeys : [ j1, t,   UNNAMED79, j2,   UNNAMED62 ]
  },
  dbHits : 956760,
  name : Extract,
  children : [ {
args : {
  _rows : 478380,
  _db_hits : 0,
  pred : NOT(j2 == j1)
},
dbHits : 0,
name : Filter,
children : [ {
  args : {
g : (j1)-['  UNNAMED62']-(t),(j2)-['  UNNAMED79']-(t),
_rows : 478380,
_db_hits : 0
  },
  dbHits : 0,
  name : SimplePatternMatcher,
  children : [ {
args : {
  identifiers : [ j1 ],
  query : {jurtid},
  producer : SchemaIndex,
  _rows : 1,
  property : jurt_id,
  label : jurt,
  _db_hits : 0,
  identifier : j1
},
dbHits : 0,
name : SchemaIndex,
children : [ ],
rows : 1
  } ],
  rows : 478380
} ],
rows : 478380
  } ],
  rows : 478380
} ],
rows : 9992
  } ],
  rows : 3
} ],
rows : 3
  }
}

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
 

profile from shell.. 

ColumnFilter(symKeys=[j1.jurt_id, j2.jurt_id,   
INTERNAL_AGGREGATEd3566f14-1679-46b2-8844-2ae2b273e7b6], 
returnItemNames=[j1.jurt_id, j2.jurt_id, commonterms], _rows=3, 
_db_hits=0)

Top(orderBy=[SortItem(Cached(  
INTERNAL_AGGREGATEd3566f14-1679-46b2-8844-2ae2b273e7b6 of type 
Integer),false)], limit=Literal(3), _rows=3, _db_hits=0)

  EagerAggregation(keys=[Cached(j1.jurt_id of type Any), 
Cached(j2.jurt_id of type Any)], aggregates=[(  
INTERNAL_AGGREGATEd3566f14-1679-46b2-8844-2ae2b273e7b6,Count(t))], 
_rows=9992, _db_hits=0)

Extract(symKeys=[j1, t,   UNNAMED79, j2,   UNNAMED62], 
exprKeys=[j1.jurt_id, j2.jurt_id], _rows=478380, _db_hits=956760)

  Filter(pred=NOT(j2 == j1), _rows=478380, _db_hits=0)

SimplePatternMatcher(g=(j1)-['  UNNAMED62']-(t),(j2)-['  
UNNAMED79']-(t), _rows=478380, _db_hits=0)

  SchemaIndex(identifier=j1, _db_hits=0, _rows=1, label=jurt, 
query={jurtid}, identifiers=[j1], property=jurt_id, 
producer=SchemaIndex)

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
 

neo4j-sh (?)$ profile match (j1:jurt)-[:HAS_TERM]-(t)-[:HAS_TERM]-(j2) 
where j1.jurt_id = {jurtid} and j2.jurt_id{jurtid} return 
j1.jurt_id,j2.jurt_id, count(t) as commonterms order by commonterms desc 
limit 3;

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J7   | J72191   | 68  |

| J7   | J73483   | 67  |

| J7   | J75683   | 66  |

+---+

3 rows

in over 7 secs ms.. 

ColumnFilter(symKeys=[j1.jurt_id, j2.jurt_id,   
INTERNAL_AGGREGATE75bdabab-2b49-42fe-9a28-4382cdb1bbf6], 
returnItemNames=[j1.jurt_id, j2.jurt_id, commonterms], _rows=3, 
_db_hits=0)

Top(orderBy=[SortItem(Cached(  
INTERNAL_AGGREGATE75bdabab-2b49-42fe-9a28-4382cdb1bbf6 of type 
Integer),false)], limit=Literal(3), _rows=3, _db_hits=0)

  EagerAggregation(keys=[Cached(j1.jurt_id of type Any), 
Cached(j2.jurt_id of type Any)], aggregates=[(  
INTERNAL_AGGREGATE75bdabab-2b49-42fe-9a28-4382cdb1bbf6,Count(t))], 
_rows=9992, _db_hits=0)

Extract(symKeys=[j1, t,   UNNAMED15,   UNNAMED32, j2], 
exprKeys=[j1.jurt_id, j2.jurt_id], _rows=478380, _db_hits=956760)

  Filter(pred=NOT(Property(j2,jurt_id(7)) == {jurtid}), _rows=478380, 
_db_hits=478380)

TraversalMatcher(start={label: jurt, query: {jurtid}, 
identifiers: [j1], property: jurt_id, producer: SchemaIndex}, 
trail=(j1)-[  UNNAMED15:HAS_TERM WHERE true AND true]-(t)-[  
UNNAMED32:HAS_TERM WHERE NOT(Property(NodeIdentifier(),jurt_id(7)) == 
{jurtid}) AND true]-(j2), _rows=478380, _db_hits=956967)

neo4j-sh (?)$ 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] Tuning/ performance / predictability

2014-03-09 Thread Tom Zeppenfeldt
Ok Michael,

- Just a question that may sound stupid :  What's  the best way to share
things privately over here ? Not seeing any clear option to do so.
- I'll try to setup a server with 2.0.1 and try to use the
shell-import-tools. FYI : uploading the 1.2M rels uring LOAD CSV took over
24 hrs ...  hope your shell-import-tools work faster ..

Best,

Tom


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-03-09 16:27 GMT+01:00 Michael Hunger michael.hun...@neopersistence.com
:

 Could you send me the profike output from the shell? Easier to read on
 mobile and also share the db with me privately

 Can you also try the query in 2.0.1?

 You can import the data using my shell-import-tools

 Or just generate textual cypher statements from load-csv

 Sent from mobile device

 Am 09.03.2014 um 16:11 schrieb Tom Zeppenfeldt tomzeppenfe...@gmail.com:

 query is executed as follows, in which I spot:

 _rows : 478380,
 _db_hits : 956760,

 which is actually higher (= worse ??)  than the original ..

 {
   columns : [ j1.jurt_id, j2.jurt_id, commonterms ],
   data : [ [ J7, J72191, 68 ], [ J7, J73483, 67 ], [
 J7, J75683, 66 ] ],
   plan : {
 args : {
   returnItemNames : [ j1.jurt_id, j2.jurt_id, commonterms ],
   _rows : 3,
   _db_hits : 0,
   symKeys : [ j1.jurt_id, j2.jurt_id, 
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 ]
 },
 dbHits : 0,
 name : ColumnFilter,
 children : [ {
   args : {
 limit : Literal(3),
 orderBy : [ SortItem(Cached(
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372 of type
 Integer),false) ],
 _rows : 3,
 _db_hits : 0
   },
   dbHits : 0,
   name : Top,
   children : [ {
 args : {
   keys : [ Cached(j1.jurt_id of type Any), Cached(j2.jurt_id
 of type Any) ],
   _rows : 9992,
   aggregates : [ (
  INTERNAL_AGGREGATEb6207bc9-3236-4e8f-ad48-51d2d73e3372,Count(t)) ],
   _db_hits : 0
 },
 dbHits : 0,
 name : EagerAggregation,
 children : [ {
   args : {
 _rows : 478380,
 _db_hits : 956760,
 exprKeys : [ j1.jurt_id, j2.jurt_id ],
 symKeys : [ j1, t,   UNNAMED79, j2,   UNNAMED62 ]
   },
   dbHits : 956760,
   name : Extract,
   children : [ {
 args : {
   _rows : 478380,
   _db_hits : 0,
   pred : NOT(j2 == j1)
 },
 dbHits : 0,
 name : Filter,
 children : [ {
   args : {
 g : (j1)-['  UNNAMED62']-(t),(j2)-['  UNNAMED79']-(t),
 _rows : 478380,
 _db_hits : 0
   },
   dbHits : 0,
   name : SimplePatternMatcher,
   children : [ {
 args : {
   identifiers : [ j1 ],
   query : {jurtid},
   producer : SchemaIndex,
   _rows : 1,
   property : jurt_id,
   label : jurt,
   _db_hits : 0,
   identifier : j1
 },
 dbHits : 0,
 name : SchemaIndex,
 children : [ ],
 rows : 1
   } ],
   rows : 478380
 } ],
 rows : 478380
   } ],
   rows : 478380
 } ],
 rows : 9992
   } ],
   rows : 3
 } ],
 rows : 3
   }
 }

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] first time a query is run it produces different results in 2.1.0-M01

2014-03-08 Thread Tom Zeppenfeldt
And yes.. it happens with other queries as well .. 

and query times are a lot longer then expected with a db of this size, 
although I indexed the crucial parts.

neo4j-sh (?)$ schema

Indexes
  ON :Person(id)ONLINE (for uniqueness constraint) 
  ON :Term(id)  ONLINE 
  ON :instantie(id) ONLINE 
  ON :jurt(jurt_id) ONLINE 
  ON :rechter(id)   ONLINE 

Constraints
  ON (person:Person) ASSERT person.id IS UNIQUE

On Saturday, 8 March 2014 18:34:17 UTC+1, Michael Hunger wrote:

 Hi Tom,

 does this happen with any database? I.e. imported by your load-csv script?

 I asked my colleagues to look into it. Perhaps related to some changes in 
 the relationship-store in Neo4j 2.1

 Do you see similar behavior also for other queries?

 Cheers,

 Michael

 
 (michael 
 http://twitter.com/mesirii}-[:SUPPORTS]-(*YOU*)-[:USE]-(Neo4jhttp://neo4j.org
 )
 Learn Online http://neo4j.org/learn/online_course, 
 Offlinehttp://www.neo4j.org/events or 
 Read a Book http://graphdatabases.com (in Deutschhttp://bit.ly/das-buch
 )
 We're trading T-shirts for cool GraphGist Models http://bit.ly/graphgist




  
 Am 07.03.2014 um 23:02 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 I have a graph db with about 1 docs  (:jurt)  and about 12000 terms 
 (t:Term) from a vocabulary. There are about 1.2M relationships of type 
  (j:jurt)-[:HAS_TERM]-(t:Term)

 To find out which documents are similar to a given document, based on a 
 count of common terms, I use this query

 match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt)
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J75312'
 with j1,j2,count(t) as commonterms
 return j1.jurt_id,j2.jurt_id,commonterms
 order by commonterms desc
 limit 3

 What I notice is that the first time the query is run, the results are 
 different from the next times... from the second time onwards, the results 
 are the same. In between, there are no other processes running..  
 Whether I run the queries from the browser, the shell or the REST API, 
 they all show the same phenomenon.

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
 desc limit 3;  

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 226 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 215 |

 +---+

 3 rows

 6288 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
 desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6299 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
 desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6354 ms

 neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
 where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
 commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
 desc limit 3;

 +---+

 | j1.jurt_id | j2.jurt_id | commonterms |

 +---+

 | J72887   | J70059   | 227 |

 | J72887   | J75312   | 220 |

 | J72887   | J77444   | 219 |

 +---+

 3 rows

 6108 ms


 What may cause this  ? 

 -- 
 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+un...@googlegroups.com javascript:.
 For more options, visit https://groups.google.com/d/optout.




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] first time a query is run it produces different results in 2.1.0-M01

2014-03-07 Thread Tom Zeppenfeldt
I have a graph db with about 1 docs  (:jurt)  and about 12000 terms 
(t:Term) from a vocabulary. There are about 1.2M relationships of type 
 (j:jurt)-[:HAS_TERM]-(t:Term)

To find out which documents are similar to a given document, based on a 
count of common terms, I use this query

match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt)
where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J75312'
with j1,j2,count(t) as commonterms
return j1.jurt_id,j2.jurt_id,commonterms
order by commonterms desc
limit 3

What I notice is that the first time the query is run, the results are 
different from the next times... from the second time onwards, the results 
are the same. In between, there are no other processes running..  
Whether I run the queries from the browser, the shell or the REST API, they 
all show the same phenomenon.

neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
desc limit 3;  

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J72887   | J70059   | 226 |

| J72887   | J75312   | 220 |

| J72887   | J77444   | 215 |

+---+

3 rows

6288 ms

neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
desc limit 3;

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J72887   | J70059   | 227 |

| J72887   | J75312   | 220 |

| J72887   | J77444   | 219 |

+---+

3 rows

6299 ms

neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
desc limit 3;

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J72887   | J70059   | 227 |

| J72887   | J75312   | 220 |

| J72887   | J77444   | 219 |

+---+

3 rows

6354 ms

neo4j-sh (?)$ match (j1:jurt)-[:HAS_TERM]-(t:Term)-[:HAS_TERM]-(j2:jurt) 
where NOT (id(j1)=id(j2)) AND j1.jurt_id = 'J72887' with j1,j2,count(t) as 
commonterms return j1.jurt_id,j2.jurt_id,commonterms order by commonterms 
desc limit 3;

+---+

| j1.jurt_id | j2.jurt_id | commonterms |

+---+

| J72887   | J70059   | 227 |

| J72887   | J75312   | 220 |

| J72887   | J77444   | 219 |

+---+

3 rows

6108 ms


What may cause this  ? 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] Re: first time a query is run it produces different results in 2.1.0-M01

2014-03-07 Thread Tom Zeppenfeldt

This is the plan that is returned with profile=true

{
  columns : [ j1.jurt_id, j2.jurt_id, commonterms ],
  data : [ [ J69478, J70059, 281 ], [ J69478, J75545, 214 ], [ 
J69478, J72887, 209 ] ],
  plan : {
args : {
  returnItemNames : [ j1.jurt_id, j2.jurt_id, commonterms ],
  _rows : 3,
  _db_hits : 0,
  symKeys : [ j1, j2.jurt_id, j1.jurt_id, commonterms, j2 ]
},
dbHits : 0,
name : ColumnFilter,
children : [ {
  args : {
limit : Literal(3),
orderBy : [ SortItem(commonterms,false) ],
_rows : 3,
_db_hits : 0
  },
  dbHits : 0,
  name : Top,
  children : [ {
args : {
  _rows : 9995,
  _db_hits : 19990,
  exprKeys : [ j1.jurt_id, j2.jurt_id ],
  symKeys : [ j1, j2, commonterms ]
},
dbHits : 19990,
name : Extract,
children : [ {
  args : {
returnItemNames : [ j1, j2, commonterms ],
_rows : 9995,
_db_hits : 0,
symKeys : [ j1, j2,  
 INTERNAL_AGGREGATE2ee63722-f8bd-482b-b98d-12f0aaf4460d ]
  },
  dbHits : 0,
  name : ColumnFilter,
  children : [ {
args : {
  keys : [ j1, j2 ],
  _rows : 9995,
  aggregates : [ ( 
 INTERNAL_AGGREGATE2ee63722-f8bd-482b-b98d-12f0aaf4460d,Count(t)) ],
  _db_hits : 0
},
dbHits : 0,
name : EagerAggregation,
children : [ {
  args : {
_rows : 519772,
_db_hits : 0,
pred : (NOT(IdFunction(j1) == IdFunction(j2)) AND 
hasLabel(j2:jurt(3)))
  },
  dbHits : 0,
  name : Filter,
  children : [ {
args : {
  start : {
identifiers : [ j1 ],
query : Literal(J69478),
producer : SchemaIndex,
property : jurt_id,
label : jurt
  },
  trail : (j1)-[  UNNAMED15:HAS_TERM WHERE 
(hasLabel(NodeIdentifier():Term(1)) AND hasLabel(NodeIdentifier():Term(1))) 
AND true]-(t)-[  UNNAMED37:HAS_TERM WHERE 
hasLabel(NodeIdentifier():jurt(3)) AND true]-(j2),
  _rows : 519772,
  _db_hits : 520531
},
dbHits : 520531,
name : TraversalMatcher,
children : [ ],
rows : 519772
  } ],
  rows : 519772
} ],
rows : 9995
  } ],
  rows : 9995
} ],
rows : 9995
  } ],
  rows : 3
} ],
rows : 3
  }
}

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] no results when not providing label ? 2.1.0-M01

2014-03-06 Thread Tom Zeppenfeldt
]{id:320247,name:Staatscourant} |
 | Node[6600]{id:320248,name:grijze literatuur} |
 | Node[6607]{id:320255,name:microreproductie}  |
 | Node[6615]{id:320263,name:jaarboek}  |
 | Node[6617]{id:320265,name:monografie}|
 | Node[6618]{id:320266,name:perscommuniqu_}|
 | Node[6626]{id:320274,name:correspondentie}   |
 | Node[6628]{id:320276,name:woordenboek}   |
 | Node[6634]{id:320282,name:toespraak} |
 | Node[6636]{id:320284,name:audiovisueel document} |
 | Node[6637]{id:320285,name:officieel document}|
 | Node[6639]{id:320287,name:parlementsstukken} |
 | Node[6647]{id:320295,name:grafische illustratie} |
 | Node[6649]{id:320297,name:incunabel} |
 | Node[6651]{id:320299,name:manifest}  |
 | Node[6652]{id:320300,name:manuscript}|
 | Node[6653]{id:320301,name:plattegrond}   |
 | Node[6656]{id:320304,name:officieel stempel} |
 | Node[6682]{id:320330,name:citaat}|
 | Node[6683]{id:320331,name:nota van toelichting}  |
 | Node[6684]{id:320332,name:elektronisch document} |
 | Node[6685]{id:320333,name:reisgids}  |
 | Node[6687]{id:320335,name:biografie} |
 | Node[6693]{id:320341,name:catalogus} |
 | Node[6694]{id:320342,name:conferentiehandelingen}|
 | Node[6700]{id:320348,name:handboek}  |
 | Node[6704]{id:320352,name:pauselijk besluit} |
 | Node[6709]{id:320357,name:offici�le verklaring}  |
 | Node[6710]{id:320358,name:vergelijkende studie}  |
 | Node[6711]{id:320359,name:casestudy} |
 | Node[6713]{id:320361,name:voorgeschiedenis}  |
 | Node[6715]{id:320363,name:atlas} |
 | Node[6717]{id:320365,name:meertalig woordenboek} |
 | Node[6719]{id:320367,name:woordenboek van afkortingen}   |
 | Node[6721]{id:320369,name:encyclopedie}  |
 | Node[6722]{id:320370,name:thesaurus} |
 | Node[6723]{id:320371,name:tijdschrift}   |
 | Node[6725]{id:320373,name:krant} |
 | Node[6728]{id:320376,name:documentair hulpmiddel}|
 | Node[6731]{id:320379,name:proefschrift}  |
 | Node[6733]{id:320381,name:bibliografie}  |
 | Node[6745]{id:320393,name:publicatie}|
 | Node[6749]{id:320397,name:verslag}   |
 | Node[6751]{id:320399,name:verslag over de werkzaamheden} |
 | Node[6753]{id:320401,name:onderzoeksverslag} |
 | Node[6756]{id:320404,name:Publicatieblad EU} |
 | Node[6760]{id:320408,name:zaakregister}  |
 | Node[6761]{id:320409,name:formulier} |
 | Node[11264]{id:324917,name:wetenschappelijke expertise}  |
 | Node[12589]{id:442333,name:EU-publicatie}|
 ++
 50 rows
 331 ms

 Am 05.03.2014 um 15:10 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 Michiel, 

 sorry I overlooked this series of questions

 On Tuesday, 4 March 2014 21:45:30 UTC+1, Michael Hunger wrote:
 The nodes that are returned, do they actually have the :Term label?

 yes they do .. tested with match (t:Term) return t.name, labels(t)  and 
  match (t:Term {name:'document'})-[:BT]-(p:Term) return p.name, 
 labels(p)  


 According to the profile it filters out the nodes on the name comparison. 
 Not on the label actually.

 Perhaps you can share the CSV and the load-csv script that you ran?

 USING PERIODIC COMMIT

 LOAD CSV FROM http://www.ophileon.com/neo4j/eurovoc_terms.csv; AS 
 csvLine 

 CREATE (t:Term { id: toInt(csvLine[0]), name: csvLine[1]})

 and 

 USING PERIODIC COMMIT

 LOAD CSV FROM  http://www.ophileon.com/neo4j/eurovoc_broader.csv; AS 
 csvLine

 MATCH (t:Term { id: toInt(csvLine[0])}),(bt:Term { id: 
 toInt(csvLine[1])}),(

 CREATE (t)-[:BT]-(bt)

 at this moment, the db only contains the :Term nodes.
  

 Michael


 Am 04.03.2014 um 21:33 schrieb Tom Zeppenfeldt tomzepp...@gmail.com:

 micheal, just a quick reply because i'm on the road:

 - it was a brand new clean install
 - nodes loaded with new LOAD FROM CSV procedure
 - no indexes added

 when i add profile=true. i get this response


 {
   columns : [ p ],
   data : [ ],
   plan : {
 args : {
   returnItemNames : [ p ],
   _rows : 0,
   _db_hits : 0,
   symKeys : [ p, t,   UNNAMED28 ]
 },
 dbHits : 0,
 name : ColumnFilter,
 children : [ {
   args : {
 _rows : 0,
 _db_hits : 9240,
 pred : Property(t,name(1)) == {term}
   },
   dbHits : 9240,
   name : Filter,
   children : [ {
 args : {
   start : {
 identifiers

Re: [Neo4j] no results when not providing label ? 2.1.0-M01

2014-03-05 Thread Tom Zeppenfeldt
Michiel, 

sorry I overlooked this series of questions

On Tuesday, 4 March 2014 21:45:30 UTC+1, Michael Hunger wrote:

 The nodes that are returned, do they actually have the :Term label?


yes they do .. tested with match (t:Term) return t.name, labels(t)  and  match 
(t:Term {name:'document'})-[:BT]-(p:Term) return p.name, labels(p)  


 According to the profile it filters out the nodes on the name comparison. 
 Not on the label actually.

 Perhaps you can share the CSV and the load-csv script that you ran?


USING PERIODIC COMMIT

LOAD CSV FROM http://www.ophileon.com/neo4j/eurovoc_terms.csv; AS csvLine 

CREATE (t:Term { id: toInt(csvLine[0]), name: csvLine[1]})

and 

USING PERIODIC COMMIT

LOAD CSV FROM  http://www.ophileon.com/neo4j/eurovoc_broader.csv; AS 
csvLine

MATCH (t:Term { id: toInt(csvLine[0])}),(bt:Term { id: toInt(csvLine[1])}),(

CREATE (t)-[:BT]-(bt)
at this moment, the db only contains the :Term nodes.
 


 Michael


 Am 04.03.2014 um 21:33 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 micheal, just a quick reply because i'm on the road:

 - it was a brand new clean install
 - nodes loaded with new LOAD FROM CSV procedure
 - no indexes added

 when i add profile=true. i get this response


 {
   columns : [ p ],
   data : [ ],
   plan : {
 args : {
   returnItemNames : [ p ],
   _rows : 0,
   _db_hits : 0,
   symKeys : [ p, t,   UNNAMED28 ]
 },
 dbHits : 0,
 name : ColumnFilter,
 children : [ {
   args : {
 _rows : 0,
 _db_hits : 9240,
 pred : Property(t,name(1)) == {term}
   },
   dbHits : 9240,
   name : Filter,
   children : [ {
 args : {
   start : {
 identifiers : [ t ],
 producer : NodeByLabel,
 label : Term
   },
   trail : (t)-[  UNNAMED28:BT WHERE true AND true]-(p),
   _rows : 9240,
   _db_hits : 9240
 },
 dbHits : 9240,
 name : TraversalMatcher,
 children : [ ],
 rows : 9240
   } ],
   rows : 0
 } ],
 rows : 0
   }
 }

 On Tuesday, 4 March 2014 02:26:45 UTC-6, Michael Hunger wrote:

 Tom:

 did you by chance upgrade from 2.0M06 ? Then you have to do a manual 
 update procedure. 
 http://blog.neo4j.org/2013/11/neo4j-200-rc1-final-preparations.html

 Did you create any indexes?
 Can you add a ?profile=true to the endpoint to show the profile

 Michael

 Am 04.03.2014 um 02:54 schrieb Tom Zeppenfeldt tomzepp...@gmail.com:

 This query to http://mydomain.com:7474/db/data/cypher

 {
   query : match (t:Term {name:{term}})-[:BT]-(p:Term) return p,
   params : {
 term : document
   }
 }

 returns the expected nodes

 however this query, just leaving out the specification of the label of p:

 {
   query : match (t:Term {name:{term}})-[:BT]-(p) return p,
   params : {
 term : document
   }
 }

 returns nothing, which I didn't expect. Did I miss something?

 -- 
 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+un...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.



 -- 
 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+un...@googlegroups.com javascript:.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] no results when not providing label ? 2.1.0-M01

2014-03-05 Thread Tom Zeppenfeldt
In the second script, there's some syntax to correct off course

it should be

USING PERIODIC COMMIT

LOAD CSV FROM  http://www.ophileon.com/neo4j/eurovoc_broader.csv; AS 
csvLine

MATCH (t:Term { id: toInt(csvLine[0])}),(bt:Term { id: toInt(csvLine[1])})

CREATE (t)-[:BT]-(bt)

On Wednesday, 5 March 2014 15:10:05 UTC+1, Tom Zeppenfeldt wrote:

 Michiel, 

 sorry I overlooked this series of questions

 On Tuesday, 4 March 2014 21:45:30 UTC+1, Michael Hunger wrote:

 The nodes that are returned, do they actually have the :Term label?


 yes they do .. tested with match (t:Term) return t.name, labels(t)  and  
 match 
 (t:Term {name:'document'})-[:BT]-(p:Term) return p.name, labels(p)  


 According to the profile it filters out the nodes on the name comparison. 
 Not on the label actually.

 Perhaps you can share the CSV and the load-csv script that you ran?


 USING PERIODIC COMMIT

 LOAD CSV FROM http://www.ophileon.com/neo4j/eurovoc_terms.csv; AS 
 csvLine 

 CREATE (t:Term { id: toInt(csvLine[0]), name: csvLine[1]})

 and 

 USING PERIODIC COMMIT

 LOAD CSV FROM  http://www.ophileon.com/neo4j/eurovoc_broader.csv; AS 
 csvLine

 MATCH (t:Term { id: toInt(csvLine[0])}),(bt:Term { id: 
 toInt(csvLine[1])}),(

 CREATE (t)-[:BT]-(bt)
 at this moment, the db only contains the :Term nodes.
  


 Michael


 Am 04.03.2014 um 21:33 schrieb Tom Zeppenfeldt tomzepp...@gmail.com:

 micheal, just a quick reply because i'm on the road:

 - it was a brand new clean install
 - nodes loaded with new LOAD FROM CSV procedure
 - no indexes added

 when i add profile=true. i get this response


 {
   columns : [ p ],
   data : [ ],
   plan : {
 args : {
   returnItemNames : [ p ],
   _rows : 0,
   _db_hits : 0,
   symKeys : [ p, t,   UNNAMED28 ]
 },
 dbHits : 0,
 name : ColumnFilter,
 children : [ {
   args : {
 _rows : 0,
 _db_hits : 9240,
 pred : Property(t,name(1)) == {term}
   },
   dbHits : 9240,
   name : Filter,
   children : [ {
 args : {
   start : {
 identifiers : [ t ],
 producer : NodeByLabel,
 label : Term
   },
   trail : (t)-[  UNNAMED28:BT WHERE true AND true]-(p),
   _rows : 9240,
   _db_hits : 9240
 },
 dbHits : 9240,
 name : TraversalMatcher,
 children : [ ],
 rows : 9240
   } ],
   rows : 0
 } ],
 rows : 0
   }
 }

 On Tuesday, 4 March 2014 02:26:45 UTC-6, Michael Hunger wrote:

 Tom:

 did you by chance upgrade from 2.0M06 ? Then you have to do a manual 
 update procedure. 
 http://blog.neo4j.org/2013/11/neo4j-200-rc1-final-preparations.html

 Did you create any indexes?
 Can you add a ?profile=true to the endpoint to show the profile

 Michael

 Am 04.03.2014 um 02:54 schrieb Tom Zeppenfeldt tomzepp...@gmail.com:

 This query to http://mydomain.com:7474/db/data/cypher

 {
   query : match (t:Term {name:{term}})-[:BT]-(p:Term) return p,
   params : {
 term : document
   }
 }

 returns the expected nodes

 however this query, just leaving out the specification of the label of p:

 {
   query : match (t:Term {name:{term}})-[:BT]-(p) return p,
   params : {
 term : document
   }
 }

 returns nothing, which I didn't expect. Did I miss something?

 -- 
 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+un...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.



 -- 
 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+un...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] no results when not providing label ? 2.1.0-M01

2014-03-04 Thread Tom Zeppenfeldt
micheal, just a quick reply because i'm on the road:

- it was a brand new clean install
- nodes loaded with new LOAD FROM CSV procedure
- no indexes added

when i add profile=true. i get this response


{
  columns : [ p ],
  data : [ ],
  plan : {
args : {
  returnItemNames : [ p ],
  _rows : 0,
  _db_hits : 0,
  symKeys : [ p, t,   UNNAMED28 ]
},
dbHits : 0,
name : ColumnFilter,
children : [ {
  args : {
_rows : 0,
_db_hits : 9240,
pred : Property(t,name(1)) == {term}
  },
  dbHits : 9240,
  name : Filter,
  children : [ {
args : {
  start : {
identifiers : [ t ],
producer : NodeByLabel,
label : Term
  },
  trail : (t)-[  UNNAMED28:BT WHERE true AND true]-(p),
  _rows : 9240,
  _db_hits : 9240
},
dbHits : 9240,
name : TraversalMatcher,
children : [ ],
rows : 9240
  } ],
  rows : 0
} ],
rows : 0
  }
}

On Tuesday, 4 March 2014 02:26:45 UTC-6, Michael Hunger wrote:

 Tom:

 did you by chance upgrade from 2.0M06 ? Then you have to do a manual 
 update procedure. 
 http://blog.neo4j.org/2013/11/neo4j-200-rc1-final-preparations.html

 Did you create any indexes?
 Can you add a ?profile=true to the endpoint to show the profile

 Michael

 Am 04.03.2014 um 02:54 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 This query to http://mydomain.com:7474/db/data/cypher

 {
   query : match (t:Term {name:{term}})-[:BT]-(p:Term) return p,
   params : {
 term : document
   }
 }

 returns the expected nodes

 however this query, just leaving out the specification of the label of p:

 {
   query : match (t:Term {name:{term}})-[:BT]-(p) return p,
   params : {
 term : document
   }
 }

 returns nothing, which I didn't expect. Did I miss something?

 -- 
 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+un...@googlegroups.com javascript:.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] no results when not providing label ? 2.1.0-M01

2014-03-04 Thread Tom Zeppenfeldt
No idea. on this particular server, which is a sandbox and has nothing else
except the java and neo4j it's happening consistently. in a DM I can
provide you the url of the instance, if that helps.

best,  Tom


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-03-04 8:55 GMT+01:00 Mark Needham m.h.need...@gmail.com:

 Hi Tom,

 That looks like it should work to me. Is it easy to recreate? Could you
 give some steps to reproduce or a small test that shows it breaking and we
 can look at it.

 Cheers
 Mark


 On 4 March 2014 01:54, Tom Zeppenfeldt tomzeppenfe...@gmail.com wrote:

 This query to http://mydomain.com:7474/db/data/cypher

 {
   query : match (t:Term {name:{term}})-[:BT]-(p:Term) return p,
   params : {
 term : document
   }
 }

 returns the expected nodes

 however this query, just leaving out the specification of the label of p:

 {
   query : match (t:Term {name:{term}})-[:BT]-(p) return p,
   params : {
 term : document
   }
 }

 returns nothing, which I didn't expect. Did I miss something?

 --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] installation issues 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt


This is what I have in /etc/neo4j-community-2.1.0-M01

https://lh3.googleusercontent.com/-oTaaGLpsWls/UwtPGjwtHJI/AP0/lP2jzWDR9qw/s1600/Screen+Shot+2014-02-24+at+7.53.50+AM.png


On Monday, 24 February 2014 01:04:18 UTC-6, Michael Hunger wrote:

 Does this directory exist? /etc/neo4j-community-2.1.0-M01/data/ and if so 
 with which user permissions?


 Am 24.02.2014 um 01:55 schrieb Tom Zeppenfeldt 
 tomzepp...@gmail.comjavascript:
 :

 Michael,


 uncommenting the line in neo4j-server.properties ( which is BTW in my case 
 in the /etc/neo4j-community-2.1.0-M01/conf folder)  did the trick :) 
  Thanks !

 However, starting up keeps complaining about a .pid file it can't find. 
 This is what my terminal shows. The .pid stuff is at the end.

 [BEGIN]

 WARNING: Max 1024 open files allowed, minimum of 40 000 recommended. See 
 the Neo4j manual.

 WARNING! You are using an unsupported Java runtime. 

 * Please use Oracle(R) Java(TM) 7 to run Neo4j Server. Download Java 
 Platform (JDK) 7 from:

   http://www.oracle.com/technetwork/java/javase/downloads/index.html

 * Please see http://docs.neo4j.org/ for Neo4j Server installation 
 instructions.

 Using additional JVM arguments:  -server -XX:+DisableExplicitGC 
 -Dorg.neo4j.server.properties=conf/neo4j-server.properties 
 -Djava.util.logging.config.file=conf/logging.properties 
 -Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC 
 -XX:+CMSClassUnloadingEnabled

 Starting Neo4j Server...fish: Could not expand string “$!”

 Standard input: /usr/bin/java -cp 
 '/etc/neo4j-community-2.1.0-M01/lib/concurrentlinkedhashmap-lru-1.3.1.jar:/etc/neo4j-community-2.1.0-M01/lib/geronimo-jta_1.1_spec-1.1.1.jar:/etc/neo4j-community-2.1.0-M01/lib/lucene-core-3.6.2.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-cypher-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-cypher-commons-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-cypher-compiler-1.9-2.0.1.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-cypher-compiler-2.0-2.0.1.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-cypher-compiler-2.1-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-graph-algo-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-graph-matching-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-jmx-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-kernel-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-lucene-index-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-shell-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/neo4j-udc-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/lib/org.apache.servicemix.bundles.jline-0.9.94_1.jar:/etc/neo4j-community-2.1.0-M01/lib/parboiled-core-1.1.6.jar:/etc/neo4j-community-2.1.0-M01/lib/parboiled-scala_2.10-1.1.6.jar:/etc/neo4j-community-2.1.0-M01/lib/scala-library-2.10.3.jar:/etc/neo4j-community-2.1.0-M01/lib/server-api-2.1.0-M01.jar:/etc/neo4j-community-2.1.0-M01/system/lib/asm-3.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/bcprov-jdk16-140.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-beanutils-1.8.0.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-beanutils-core-1.8.0.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-collections-3.2.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-compiler-2.6.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-configuration-1.6.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-digester-1.8.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-io-1.4.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-lang-2.4.jar:/etc/neo4j-community-2.1.0-M01/system/lib/commons-logging-1.1.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jackson-core-asl-1.9.7.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jackson-jaxrs-1.9.7.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jackson-mapper-asl-1.9.7.jar:/etc/neo4j-community-2.1.0-M01/system/lib/janino-2.6.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/javax.servlet-3.0.0.v201112011016.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jcl-over-slf4j-1.6.1.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jersey-core-1.9.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jersey-multipart-1.9.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jersey-server-1.9.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-http-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-io-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-security-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-server-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-servlet-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-util-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-webapp-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jetty-xml-9.0.5.v20130815.jar:/etc/neo4j-community-2.1.0-M01/system/lib/jsr311-api-1.1.2.r612.jar:/etc/neo4j-community-2.1.0-M01/system/lib/logback-access-1.0.9.jar:/etc/neo4j-community-2.1.0-M01/system/lib

Re: [Neo4j] installation issues 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt


 Michael,


with bash everything went ok:

so complete procedure with new machine

- unzip tar.gz
- install java sdk 7 
- uncomment org.neo4j.server.webserver.address=0.0.0.0  in 
neo4j-server.properties 
- ./bin/neo4j start

no more fish for me!


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[Neo4j] New LOAD CSV functionality in 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt
Hi, played a little bit with this 
http://docs.neo4j.org/chunked/milestone/import-importing-data-from-multiple-csv-files.html
 
, seems working nicely as long as you have a separate relation file for 
each relation-type.

Is it possible to read the relation type from the csv using this procedure 
? Perhaps it's already possible and do I need to know the correct syntax. 

LOAD CSV FROM http://www.myserver.com/neo4j/relations.csv; as csvLine 
MATCH (p:Person { id: toInt(csvLine[0])}),(p2:Person { id: 
toInt(csvLine[1])})
CREATE (p)-[:csvLine[2]]-(p2) 




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] installation issues 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt


 Thank you too. You may want to have this somewhere on your  How to 
 install pages especially the 0.0.0.0 part  :) 


BTW :  another reason why the debian package didn't work (probabbly) :  I 
was running Ubuntu  :)  stupid me 

Best Tom

 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[Neo4j] Re: New LOAD CSV functionality in 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt


 As you say , it's kinda horrible .. but as a workaround it will do for the 
 moment :)


 

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[Neo4j] Re: New LOAD CSV functionality in 2.1.0-M01

2014-02-24 Thread Tom Zeppenfeldt
Another thing I noticed:

When uploading a file with about 8000 thesaurus relations, and although I 
used a construct like 

USING PERIODIC COMMIT
LOAD CSV FROM  http:/myserver.com/neo4j/eurovoc_broader.csv  AS csvLine
MATCH (t:Term { id: toInt(csvLine[0])}),(bt:Term { id: toInt( csvLine[1])})
CREATE (t)-[:BT]-(bt)

I got Unknown errors quite often. I really had to find out by trial and 
error what the maximum size was.  If i went over it, I got an  Unknown 
error  and had to start all over again. Would be very nice to have a 
setting that allows me to force a commit after a certain number of 
processed rows and just let the server do its work, regardless of the 
length of the csv file.  In my case, I had to cut the file into 17 separate 
csv's and feed them one by one to the server.




-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[Neo4j] installation issues 2.1.0-M01

2014-02-23 Thread Tom Zeppenfeldt
tried to get in running on my server , but can't get it running

- downloaded the Mac/Linux tar.gz
- extracted in to my debian machine to a new dir
- when  ./bin/neo4j start , I get this

root@NOWledge /e/neo4j-community-2.1.0-M01# ./bin/neo4j start

WARNING: Max 1024 open files allowed, minimum of 40 000 recommended. See 
the Neo4j manual.

WARNING! You are using an unsupported Java runtime.

1) haven't been able to find a manual that indicates where to set files to 
40 000 ( sorry if I overlooked it)

2) java version seems ok..

root@NOWledge /e/neo4j-community-2.1.0-M01# java  -version
java version 1.7.0_25
OpenJDK Runtime Environment (IcedTea 2.3.12) (7u25-2.3.12-4ubuntu3)
OpenJDK 64-Bit Server VM (build 23.7-b01, mixed mode)

Any help appreciated

Best,


Tom



-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Neo4j] installation issues 2.1.0-M01

2014-02-23 Thread Tom Zeppenfeldt
-Djava.util.logging.config.file=conf/logging.properties
-Dlog4j.configuration=file:conf/log4j.properties -XX:+UseConcMarkSweepGC
-XX:+CMSClassUnloadingEnabled
-Dneo4j.home=/etc/neo4j-community-2.1.0-M01
-Dneo4j.instance=/etc/neo4j-community-2.1.0-M01
-Dfile.encoding=UTF-8 org.neo4j.server.Bootstrapper 
/etc/neo4j-community-2.1.0-M01/data/log/console.log 21  echo $! 
/etc/neo4j-community-2.1.0-M01/data/neo4j-service.pid





























































  ^

cat: /etc/neo4j-community-2.1.0-M01/data/neo4j-service.pid: No such file or
directory

process []... waiting for server to be ready. Failed to start within 120
seconds.

Neo4j Server may have failed to start, please check the logs.

rm: cannot remove '/etc/neo4j-community-2.1.0-M01/data/neo4j-service.pid':
No such file or directory

root@NOWledge /e/neo4j-community-2.1.0-M01#


Met vriendelijke groet / With kind regards



Ir. T. Zeppenfeldt
van der Waalsstraat 30
6706 JR  Wageningen
The Netherlands

Mobile: +31 6 23 28 78 06
Phone: +31 3 17 84 22 17
E-mail: t.zeppenfe...@ophileon.com
t.zeppenfe...@ophileon.comWeb: www.ophileon.com
Twitter: tomzeppenfeldt
Skype: tomzeppenfeldt


2014-02-23 13:47 GMT-06:00 Mark Needham m.h.need...@gmail.com:

 Hey

 Those are just warnings - they shouldn't stop it from starting. Can you
 paste the contents of data/log/console.log?

 Mark


 On 23 February 2014 19:43, Tom Zeppenfeldt tomzeppenfe...@gmail.comwrote:

 tried to get in running on my server , but can't get it running

 - downloaded the Mac/Linux tar.gz
 - extracted in to my debian machine to a new dir
 - when  ./bin/neo4j start , I get this

 root@NOWledge /e/neo4j-community-2.1.0-M01# ./bin/neo4j start

 WARNING: Max 1024 open files allowed, minimum of 40 000 recommended. See
 the Neo4j manual.

 WARNING! You are using an unsupported Java runtime.

 1) haven't been able to find a manual that indicates where to set files
 to 40 000 ( sorry if I overlooked it)

 2) java version seems ok..

 root@NOWledge /e/neo4j-community-2.1.0-M01# java  -version
 java version 1.7.0_25
 OpenJDK Runtime Environment (IcedTea 2.3.12) (7u25-2.3.12-4ubuntu3)
 OpenJDK 64-Bit Server VM (build 23.7-b01, mixed mode)

 Any help appreciated

 Best,


 Tom



  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


  --
 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+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[Neo4j] Re: ignore case search Neo4j

2014-01-30 Thread Tom Zeppenfeldt
Case insensitive searches can be done with regular expressions, e.g.

match (n:Person) 
where n.name=~'(?i).*a.*' 
return n.name

which would also return results including Andre, andre, Michael


On Thursday, 30 January 2014 14:17:53 UTC+1, Navrattan Yadav wrote:

 hi. i am using Neo4j 2.0. I want to search by a properties value with 
 ignore case and also with like operator.

 eg. Node has properties   Name : John Michle

 then want to search by : john, John,john Michle etc.

 i try  : 

 START n = node:Name(Name=*john*) 
 return n;

 but not get result.


-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.