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 different between SqlCommand object and Command
Behaviour Object

Answer Posted / sudhir kumar pal

ADO.NET Command Object - The Command object is similar to
the old ADO command object. It is used to store SQL
statements that need to be executed against a data source.
The Command object can execute SELECT statements, INSERT,
UPDATE, or DELETE statements, stored procedures, or any
other statement understood by the database. See sample
code...

'Code below in VB.NET ...
Dim ObjCom as SqlClient.SqlCommand
ObjCom.SqlConnection(strCon)
ObjCom.Connection.Open()
ObjCom.CommandText = "Select * from tblSample"
ObjCom.ExecuteNonQuery()


SqlCommand objects are not used much when we use datasets
and data adapters. Following are some properties of the
SqlCommand class...

Is This Answer Correct ?    9 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is ado control?

995


What do you know about ado.net's methods?

1168


What is the default Timeout for SqlCommand.CommandTimeout property?

1063


What is difference between ado and other data object?

966


What are the essential features of ado.net?

1007


What is commandbuilder in ado.net?

1095


Explain the architecture of ado.net?

1129


What is meant by executenonquery?

988


What is the return type of executescalar?

1069


How to retrieve the user id which is provided while windows authentication?

1144


How will you differentiate between ADO (ActiveX Data Object) and RDO (Remote Data Objects)?

1082


What is connection in ado.net?

997


What are the data providers in ADO.NET framework?

1074


What is Data Provider?

1089


What is the difference between Optimistic and Pessimistic locking?

1034