3 questions.
1. How many rows are returned by SELECT * FROM Tbl WHERE Col2 =@P1
2. Do both updates use the same value assigned to @P1?
3. Is updated column - SET Col=@P0 - different from Col2? What kind of value is assigned to it? Does it participate in any indexes?
_____________
Code for TallyGenerator