How can we fine-tune the command object when we are expecting a single row?

 Posted by ArticlesMaint on 9/17/2009 | Category: ADO.NET Interview questions | Views: 5172

Answer: -
Again, CommandBehaviour enumeration provides two values Single Result and Single Row. If you are expecting a single value then pass “CommandBehaviour.SingleResult” and the query is optimized accordingly, if you are expecting single row then pass “CommandBehaviour.SingleRow” and query is optimized according to single row.

Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response