Thanks a lot for the clarifications Davide! I've ran both tests again though, and although both tests are consistent now, it doesn't seem to be entirely correct. On a first run, the tests return the following:
Code:
Persons:1
Items:2
0
1 value_sequence_ogm - 3, id_sequence_ogm - hibernate_sequencessequence_namePerson,
2 value_sequence_ogm - 5, id_sequence_ogm - hibernate_sequencessequence_nameItem,
3 id - 1, lastName - Doe, _table - Person, firstName - John,
4 id - 1, name - iPhone, _table - Item,
5 id - 2, name - iPod, _table - Item,
6 persons_id - 1, items_id - 1,
7 persons_id - 1, items_id - 2,
8 persons_id - 1, items_id - 2,
9 persons_id - 1, items_id - 1,
This means there is one person and two items found. This is correct, but I'm wondering what the difference between node 6 and 9, and node 7 and 8 is? They seem to be identical, so is this a bug? Maybe you can explain a bit what node sturcture is used by OGM?
Anyway, on a second run, this is the output:
Code:
Persons:1
Items:2
0
1 value_sequence_ogm - 3, id_sequence_ogm - hibernate_sequencessequence_namePerson,
2 value_sequence_ogm - 5, id_sequence_ogm - hibernate_sequencessequence_nameItem,
3 id - 1, lastName - Doe, _table - Person, firstName - John,
4 id - 1, name - iPhone, _table - Item,
5 id - 2, name - iPod, _table - Item,
6 persons_id - 1, items_id - 1,
7 persons_id - 1, items_id - 2,
8 persons_id - 1, items_id - 2,
9 persons_id - 1, items_id - 1,
10 id - 2, lastName - Doe, _table - Person, firstName - John,
11 id - 3, name - iPhone, _table - Item,
12 id - 4, name - iPod, _table - Item,
13 persons_id - 2, items_id - 4,
14 persons_id - 2, items_id - 3,
15 persons_id - 2, items_id - 3,
16 persons_id - 2, items_id - 4,
If you look at the Neo4j contents, it appears that there are now 2 persons and 4 items stored. This is correct. But the queries still return Persons:1 and Items:2. Again, is this a bug or am I simply missing something?