What are the steps in connecting to database?
Answer Posted / chaitanya.k
1. U need to declare name space according to which database
u need to connect.
2. U can declare connection string in two ways.
1. U can declare in web.config in appsettings.
2. U can delare directly in code behind or in inline code
These can delared by using connection string.
3. Then u can do the operations by open the connection.
4. After complete all ur transcations u need to close the
database.
Is This Answer Correct ? | 10 Yes | 3 No |
Post New Answer View All Answers
What is method to get XML and schema from Dataset? getXML() and get Schema ()
What is difference between Dataview and Datatable?
What are the data access namespaces in .NET?
What is the functionality of data provider in ado.net?
What is linq and entity framework?
What is a data control clerk?
What is ado and rdo?
Why do we need ado.net?
What are the parameters that control most of connection pooling behaviors?
What are disadvantages of microsoft-provided data provider classes in ado.net?
How can we load multiple tables in to dataset?
What are the drawbacks of using ado.net?
Does sqlclient and oledb class share the same functionality?
What are the different execute methods of Ado.Net?
What are the advantages and drawbacks of using ado.net?