Further to this problem. I am now trying to delete all the duplicates. This
is the query I am using to find duplicates. Running this reports no
duplicates however, creating the constraint finds duplicates and the
constraint condition cannot be created.
MATCH (t:Tweet)
ORDER BY id(t) DESC // Order by descending to delete the most
recent duplicated record
WITH t.id as DuplicateKey, COUNT(u) as ColCount, COLLECT(ID(u)) as
ColNode
WITH DuplicateKey, ColCount, ColNode, HEAD(ColNode) as DuplicateId
WHERE ColCount > 1 AND (DuplicateKey is not null) AND (DuplicateId
is not
null)
WITH DuplicateKey, ColCount, ColNode, DuplicateId
ORDER BY DuplicateId
//RETURN DuplicateKey, ColCount, DuplicateId
//Toggle comment on/off for validating duplicate records before moving to
next step (do not proceed to delete without validating)
RETURN COLLECT(DuplicateId) as CommaSeparatedListOfIds
On Monday, 3 November 2014 09:22:50 UTC, John Swain wrote:
>
> I was doing a large number of merge operations adding a new property to
> around 5m nodes.
>
> During testing I noticed that the merge seemed to be creating spurious new
> nodes breaking the Constraint condition. It turns out that the index was
> out of sync and the merge was not finding the existing record therefore
> creating a new one.
>
> I deleted the Lucene folder and restarted Neo4j - which fixed the problem.
>
> Here is a screenshot http://www.screencast.com/t/QkfzT1ye
>
> I would like to know how to avoid this occurring in future and if it is a
> known problem. I have searched the group but not found any report if this
> issue. This is a pretty serious bug for me as I need to do many of these
> merge operations and need to be sure it is reliable.
>
> I am using Neo4j Enterprise 2.1.5 Personal Edition on a Mac running
> Yosemite. Happy to provide any further information if required.
>
> regards,
> js
>
--
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 [email protected].
For more options, visit https://groups.google.com/d/optout.