apoc.coll.unionAll

Function APOC Core

apoc.coll.unionAll(first, second) - creates the full union with duplicates of the two lists

Signature

apoc.coll.unionAll(first :: LIST? OF ANY?, second :: LIST? OF ANY?) :: (LIST? OF ANY?)

Input parameters

Name Type Default

first

LIST? OF ANY?

null

second

LIST? OF ANY?

null

Usage Examples

The following creates the full union of two lists:

RETURN apoc.coll.unionAll([1,2,3,4,5], [3,4,5,6,7]) AS output;
Table 1. Results
Output

[1, 2, 3, 4, 5, 3, 4, 5, 6, 7]