Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
mr_blore
Starting Member
7 Posts |
Posted - 2004-11-05 : 07:18:48
|
Hi..I am not able to capture a syntax error in @@ERROR variable.Errors like 'Syntax error converting the varchar value to a column of data type int'I assume that its not the job of @@ERROR....But i need to know a way to handle such errors in the Stored procs. My SP would have some "out" paramters. but if an syntax error like the above occurs, then my SP fails and sothe "out" param is not populated.Any suggestions!!! ThanksMeera"If you think you can, it means you can think!"  |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-11-05 : 08:00:54
|
| Sometimes you can trap these type of errors if you EXEC some dynamic code, or put them in a child SProc and check @@ERROR after the EXEC/Child Proc returnsKristen |
 |
|
|
|
|
|