Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What are the namespaces used in ADO.Net to connect to a database?

1225


Which object needs to be closed?

2273


What are two important objects of ADO.Net?

1037


How to store data in memory?

962


How can you identify whether or not any changes are made to the DataSet object since it was last loaded?

1050


What is the difference between oledb sql server and oledbdotnet provider?

1022


Explain the basic use of "dataview" and explain its methods.

1009


What is executequery?

962


What is ado object model?

957


Command objects uses, purposes and their methods.

994


How to enable and disable connection pooling?

1069


Which is the best method to get two values from the database?

980


What are the important features of ado.net 2.0?

1082


What is ado.net connection?

973


What is a serialized object?

1036