How can you get @@error and @@rowcount at the same time?
Answer Posted / laxman
SELECT @RC = @@ROWCOUNT
SELECT @ER = @@ERROR
if we use above statements then @@error will be reset with
0.
i think right one is
select @er=@@error,@rc=@@rowcount
| Is This Answer Correct ? | 31 Yes | 1 No |
Post New Answer View All Answers
Can a table have 2 primary keys?
What is difference between createstatement and preparedstatement?
What is the contrast between sql and pl/sql?
How do I find sql server instance name?
What are the advantages of user defined function?
Explain concepts of analysis services?
After creating the cube, if we added a new column to the oltp table then how you add this new attribute to the cube? : sql server analysis services, ssas
Is candidate a key?
sql database suspect We have a sql database that is showing as suspect. How can we recover?
What program is used to store the data source file?
What is data compression?
What is the need for indexing?
what are constraints? Explain different types of constraints? : Sql server database administration
What are the encryption mechanisms in sql server?
What are the approximate numeric data types?