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 is the difference between DataReader and DataSet in ADO.NET?

1095


What is ado oledb and odbc?

891


How can I retrieve two tables of data at a time by using data reader? Data reader read and forward only, how is it possible to get 2 tables of data at a time?

930


If we are not returning any records from the database, which method is to be used?

1292


How to check if the Dataset has records ?

959


What do you mean by ‘batch updates’?

999


Explain what is datagrid with an example?

1051


Define the executescalar method?

890


What are the different methods by which we can populate a dataset?

1195


What are the benefits of using of ADO.NET in .NET 4.0?

1007


What is serialization and de-serialization in .net? How can we serialize the dataset object?

916


If a table contains 20000 records. In a page at each time 100 records to be displayed.

853


What is oledb connection?

950


Describe connection object in ado.net

1001


What is the difference between a datareader and a dataset?

962