Methods provided by the command object, DOT NET Programming

What are the methods provided by the command object?

The command objects used to connect the connection object to the Datareader or the dataset. The command object provided some methods which are as shown below :-

1)Execute Non Query :- It executes the command defined in the CommandText property against the connection defined in the Connection property for a query which  does not return any row (an UPDATE, DELETE or INSERT). It returns an Integer showing the number of rows affected by the query.

2)ExecuteReader :- It executes the command defined in the Command Text property against the connection defined in the Connection property. It gives the "reader" object which is connected to the resulting rowset inside the database,& allowing the rows to be retrieved.

3)Execute Scalar :- It executes the command defined in the CommandText property against the connection defined in the Connection property. It Returns only  the single value (effectively the Ist column of the Ist row of the resulting rowset) any other returned columns &  rows are discarded. It is fast and efficient when only a "singleton" value is needed.

Posted Date: 9/24/2012 2:23:04 AM | Location : United States







Related Discussions:- Methods provided by the command object, Assignment Help, Ask Question on Methods provided by the command object, Get Answer, Expert's Help, Methods provided by the command object Discussions

Write discussion on Methods provided by the command object
Your posts are moderated
Related Questions
What is "Common Type System" (CTS)?  CTS define all of the basic types that can be used  in the .NET Framework and the operations performed on those type. All this time we have

EMR ONC MU2 CERTIFICATION Project Description: We are looking for someone with experience in EMR MU2 certification per ONC needs. If you have experience and participate in

Excel Assistant Need somebody to duplicate/create an excel spreadsheet and to make it website friendly. Desired Skills are VB.NET, VBA, C++, macros, webdesign

I am seeking someone (person or company) who already has been developing some ASP.NET MVC 4 application with the subsequent requirements (so there is no need to spend extra time to

What is CTS and CLS? => CLS stands for common language specification where as CTS stands for common type system. => CLS : cls is a standard for .net . cls is small set of sp

Importance of IT governance Governing and managing information technology is a crucial activity in organizations to generate business value. According to Ross & Weill (2004), f

They are triggered in the following order as shown below: Application_BeginRequest Application_AuthenticateRequest Application_AuthorizeRequest Application_ResolveReque

Jquery and MVC 4.5 Training Session I am looking who have industry experience working on Microsoft Technology ( MVC 4.5 ) and Jquery, who will take live online session and provi

What is Six Sigma implementation? To attain Six Sigma is a team effort and cannot be attained individually. Driving the Six Sigma itself in an organization is vast project as i

Project Description: We need to construct services in C# or VB.NET that can manipulate with a Targin TIP Protocol Server (protocol for financial information exchange), receive d