How to Handle the exceptions in Sqlsrver 2005??
Answer Posted / indraneelandhavarapu
With SQL Server 2005, new error handling has been introduced
with the TRY...CATCH processing. Basically what happens is
when an error occurs the processing in the TRY block stops
and processing is then picked up in the CATCH block.
ERROR_NUMBER() Returns the number of the error
ERROR_SEVERITY() Returns the severity
ERROR_STATE() Returns the error state number
ERROR_PROCEDURE() Returns the name of the stored procedure
or trigger where the error occurred
ERROR_LINE() Returns the line number inside the routine
that caused the error
ERROR_MESSAGE() Returns the complete text of the error
message. The text includes the values supplied for any
substitutable parameters, such as lengths, object names, or
times
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
List out different types of normalizations in sql server and explain each of them?
What is partition in sql server?
Can we take the full database backup in log shipping?
What do you understand by user-defined function in the sql server?
How to fine-tune reports?
Tell me about joins in database system and explain each in detail.
How many categories of functions based their return modes?
How many databases can we create in a single server?
Explain system views?
What were the latest updates to SQL Azure service?
What are the export options of ssrs?
What is simple indexing method?
How to check table values in sql server?
How to use "begin ... End" statement structures in ms sql server?
How to insert stored procedure result into temporary table?