Hello.

You need either
SELECT ID, ARRAY_AGG(DISTINCT Item) Item FROM tbl2 GROUP BY ID
or
SELECT ID, GROUP_CONCAT(DISTINCT Item SEPARATOR ', ') Item FROM tbl2 GROUP 
BY ID
depending on data type of expected result. Use ARRAG_AGG for ARRAY result 
or GROUP_CONCAT for VARCHAR result.

ARRAY_AGG is not available before H2 1.4.197, so use a recent version of H2.

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to