Execute nonquery returns no. of afected rows.So if my stored
procedure hav lot of select stmnt, delete stmnt, insert
stmnt..then what does execute nonquery returns in this case?
Answer Posted / sandyni
Execute nonquery effects only for DML like Update delete
and insert statements only,
for select statement we have to choose ExecuteScalar or
ExecuteReader methods. these methods can return datareader
and gives the result for your query.
Is This Answer Correct ? | 18 Yes | 6 No |
Post New Answer View All Answers
How do you update database through dataset?
Why is stored procedure used in ado.net?
How to check if a datareader is closed or opened? IsClosed()
What is ado control?
How to work with disconnected data - the dataset and sqldataadapter?
What are two important objects of ADO.Net?
What is maximum pool size in ado.net connection string?
What are ado.net objects?
Which is better entity framework or ado.net?
What does executereader return?
What is the difference between Dataset. clone and Dataset.copy?
Which name space is used to get assembly details?
Name which operations can you not perform on an ado.net dataset?
What is XML serialization
Which object holds only data and does not interact with data source?