Re: Stored Procedure returns nothing on ROLLBACK
| From: | Chris | Date: | Thu, 11 Jan 2007 00:36:44 +0000 |
| Subject: | Re: Stored Procedure returns nothing on ROLLBACK | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-246872@lists.php.net to get a copy of this message | ||
Philip Thompson wrote:
Hi. I have been experiencing MSSQL woes lately. I have a stored procedure that I call in PHP using mssql_* functions. In my procedure, I have a transaction that rolls back on failure and commits on success (of course). If it commits, I get the proper return value (int) and the appropriate output parameters. However, if it rolls back, I get NOTHING... even if I try to return an error code (int) after the ROLLBACK TRANSACTION statement. The output parameter also does not get set upon rollback. Is there a way to grab the error even in a rollback? or at least return something besides an empty string/int? I would like to know what error message to provide the user/admin. SQL Server 2000, PHP 5.1.6, ntwdblib.dll version 8.00.194Does it work outside of php? That is - you run it manually in mssql (whatever tools that has) you get the proper codes? -- Postgresql & php tutorials http://www.designmagick.com/