C# Corner
Tech
News
Videos
Forums
Jobs
Books
Events
More
Interviews
Live
Learn
Training
Career
Members
Blogs
Challenges
Certification
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
.NET
ADO.NET
Android
ASP.NET
C#
Databases & DBA
Design Patterns & Practices
iOS
Java
OOP/OOD
SharePoint
Software Testing
Web Development
WPF
View All
6
Reply
What is the use of command Object?
Rahul Pandey
12y
2.2k
0
Reply
Delete Row
Delete Column
Insert Link
×
Insert
Cancel
Embed YouTube Video
×
Width (%)
Height (%)
Insert
Cancel
Table Options
×
Rows
Columns
First row as header
Create Table
Insert Image
×
Selected file:
Alignment
Left
Center
Right
Select an image from your device to upload
Upload to Server
Cancel
Submit
Command object is used to initialize database commands.SqlCommand cmd = new SqlCommand("select * from employee",conn); here we are passting a sqlcommand as s string and also a connection object as parameter to the SqlCommand instance constructor. and those are gets initialized in the instance constructor. when we call the other merthods of commad class such as ExecuteReader() ExecuteScalar() and ExecuteNonQuery() methods will execute those commands
Srinivas Pabballa
10y
0
Command is used to execute almost any SQL command from within the .net application.
Vithal Wadje
11y
0
The ADO Command object is used to execute a single query against a database. The query can perform actions like creating, adding, retrieving, deleting or updating records.If the query is used to retrieve data, the data will be returned as a RecordSet object. This means that the retrieved data can be manipulated by properties, collections, methods, and events of the Recordset object.The major feature of the Command object is the ability to use stored queries and procedures with parameters.
Munesh Sharma
11y
0
SQL Command is ADO.Net Object and it used for execute the query,Stored Procedures and get the result. SQLCommand object Return Integer value.
Pramod Lawate
12y
0
command object is used to execute any backend queries or stored procedure from the presentation layer.
Poornima
12y
0
command object is used to provide the sql command from fron end.
Srikanth Reddy
12y
0
How to creating a SqlCommand Object?
What is the provider and namespaces being used to access oracle database?
Message