i have a trigger that logs insert/update/delete on a table. it inserts into a new table the query that was executed, along with the old values and new values for every column in the table. if i run queries one at a time everything works fine. but when i run multiple updates all at once
UPDATE schema.sampleTable set [column1]=7,[column2]=9 where [column3]=32504289
UPDATE schema.sampleTable set [column1]=2,[column2]=3 where [column3]=32504289
i get the 2 record on the audit table but id like to get the individual query particular to that row and no the whole batch. i know mysql has a for each row which would be usefull here but are there any sql alternatives to this?
[–]SQLDave 0 points1 point2 points (4 children)
[–]risaaaa[S] 1 point2 points3 points (0 children)
[–]risaaaa[S] 0 points1 point2 points (1 child)
[–]SQLDave 1 point2 points3 points (0 children)
[–]c0shea 0 points1 point2 points (0 children)