How would I access the bSuccess variable in my ColdFusion code? Wouldn't I have to create a variable to return and set @@rowcount to that variable like so?
CREATE PROCEDURE dbo.sp_delete @id int, @outRecCount int OUT AS DELETE FROM Foo WHERE Bar = 1 SET @outRecCount = @@Rowcount Thanks again for the quick responses. Dave -----Original Message----- From: Mike Townend [mailto:[EMAIL PROTECTED] Sent: Friday, June 20, 2003 8:04 AM To: SQL Subject: RE: Confirm a successful execution of a query? I tend to use this SET NOCOUNT ON DELETE FROM Foo WHERE Bar = 1 SELECT bSuccess = @@ROWCOUNT SET NOCOUNT OFF Then you will be returned a query object, that if its > 0 then it was successful..l. HTH -----Original Message----- From: Bosky, Dave [mailto:[EMAIL PROTECTED] Sent: Friday, June 20, 2003 13:01 To: SQL Subject: Confirm a successful execution of a query? I'm using MS SQL 2000 stored procedures for updating/deleting records on my website. When I call a SP that updates/deletes a specific record is there any way to verify the record was actually updated/deleted? Is there a certain variable I can check that SQL uses as a flag to indicate whether a query was successful or not? Thanks, Dave HTC Disclaimer: The information contained in this message may be privileged and confidential and protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer. Thank you. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=6 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=6 Get the mailserver that powers this list at http://www.coolfusion.com
