Mysql insert - how to get ids of multiple row

I am able to successfully mysql insert multiple records with a single node execution. however, the results returns only first row id. how to get the all the row id’s inserted.

In above scenario , 5 records are inserted, but insertid is returning only 203 which is the first record. How to retrieve the rest of 4 records i,e 204,205,206 & 207

Hi @Surendra_NV, the respective MySQL function only returns the last ID: https://dev.mysql.com/doc/refman/8.0/en/information-functions.html#function_last-insert-id

If you need all IDs you might want to use the Split in Batches node to split your items into batches of 1, then insert them each individually.

Thanks. Will try it

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.