apoc.coll.duplicates

Function APOC Core

apoc.coll.duplicates(coll) - returns a list of duplicate items in the collection

Signature

apoc.coll.duplicates(coll :: LIST? OF ANY?) :: (LIST? OF ANY?)

Input parameters

Name Type Default

coll

LIST? OF ANY?

null

Usage Examples

The following returns a list of duplicates in a list:

RETURN apoc.coll.duplicates([1,3,5,7,9,9]) AS output;
Table 1. Results
Output

[9]