I am not able to use the below SQL in QMF mainframes. I am getting syntax error (-199 SQLCODE). Seems like the LISTAGG function is available only for Unix, Linux and Windows.. Is there any equivalent command for mainframes?
We are using DB2 Version 11.1
SELECT NAME, LISTAGG(TBNAME, ',') WITHIN GROUP (ORDER BY TBNAME) AS C
FROM SYSIBM.SYSCOLUMNS WHERE
NAME = 'AC_XTNL_SQ_NO' GROUP BY NAME;
Thanks
Prasanna G.