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
Which method is used to sort the data in ADO.Net?
What are all features of ADO.Net?
What are the rules to implement connection pooling?
What is a data control clerk?
What is a datareader object?
Do you use stored procedure in ado.net?
What are dataproviders?
What is data control techniques?
Explain the two fundamental objects in ado.net?
What are two important objects of ADO.Net?
What is connected architecture in ado.net?
What are the steps you will take to improve performance?
How to pass multiple tables in datasets simultaneously?
How will you fill the gridview by using datatable object at runtime?
What does executequery return?