H
Henry
I have a stored procedure that runs two update statements within a
transaction and rollsback the transaction if the second update statement
returns an @@ROWCOUNT of 0.
The stored procedure flags records for printing.
The first update statement clears any flags that were set from the previous
printout and the second statement flags the new records for printing, if no
new records are flagged for printing then I want to restore the original
flags from the previous printout.
This stored procedure is being called by an ADP and I would like to know
whether the second update statement updated and rows or now (@@RowCount>0)
If no new records are flagged for printing then I need to know so that I can
decided whether or not to print the report in Access.
Can I simply check the RecordAffected property using:
command.Execute RecordsAffected, Parameters, Options
My concern is that this may report the resulys of the first update statement
in the sp, I am only interested in the results of the second update
statement.
Thanks
Henry
transaction and rollsback the transaction if the second update statement
returns an @@ROWCOUNT of 0.
The stored procedure flags records for printing.
The first update statement clears any flags that were set from the previous
printout and the second statement flags the new records for printing, if no
new records are flagged for printing then I want to restore the original
flags from the previous printout.
This stored procedure is being called by an ADP and I would like to know
whether the second update statement updated and rows or now (@@RowCount>0)
If no new records are flagged for printing then I need to know so that I can
decided whether or not to print the report in Access.
Can I simply check the RecordAffected property using:
command.Execute RecordsAffected, Parameters, Options
My concern is that this may report the resulys of the first update statement
in the sp, I am only interested in the results of the second update
statement.
Thanks
Henry