What is @@rowcount and with small code snippet explain the
usage?
Answer Posted / guest
@@rowcount gives the number of rows given as an result of
previous query ran.
Create procedure get_emp_count ( @emp_id int)
As
Select * from emp where emp_id =@emp_id
If @@rowcount = 0
Begin
Select 'no rows with emp_id= '
Select @emp_id
End
| Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
What is disconnected architecture in ado.net?
What are the difference between readonly vs. Const?
Which property is used to check whether a DataReader is closed or opened?
What is ado full form?
How will you fill the gridview by using datatable object at runtime?
Do you use stored procedure in ado.net?
How to create dynamic gridview?
What is the difference between sqlcommand and sqldataadapter?
What is commandbuilder in ado.net?
What is the difference between Response.Expires and Reponse.ExpiresAbsolute?
Define Execute Scalar?
What is disconnected data?
How would you connect to database using .NET?
How to find the given query is optimised one or not?
What is Dataset Object?