So this code works great for a single call, muti-row INSERT:
but when I take out just the INSERT statement to simply return the results, I can't get around this error:
'[IBM][CLI Driver][DB2/LINUXX8664] SQL0104N An unexpected token "with" was found following "from avgs do". Expected tokens may include: "FOR". LINE NUMBER=1. SQLSTATE=42601\n'
says either INSERT, WITH and others are all ok after the DO.
Code does SQLPrepare initially then followed by SQLExecute, which gets the error. Environment is node, node-odbc and db2 10.5.
Thanks for any help!!