Answer Posted / senthil kumar
using OLEDB connection we can connect the MS-ACCESS,Sql
Server,Oracle.
here i given the coding for connect the oledb connection
OleDbConnection con = new OleDbConnection();
con.ConnectionString="Provider=Microsoft.Jet.OleDb.4.0;Data
Source=databasenamewithpath;";
con.Open();
then u can use the dataset or datareader
OleDbCommand cmd = new OleDbCommand(sql,con);
cmd.CommandType = CommandType.Text;
cmd.ExecuteNonQuery();
OleDbDataReader reader;
reader = cmd.ExecuteReader();
OleDbDataAdapter oda = new OleDbDataAdapter(sql,con);
DataSet ds = new DataSet();
oda.Fill(ds,"tablename");
i hope that these are enough.
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
Define ado.net?
What are the benefits of using ado.net?
What are the connected and disconnected modes in ado.net?
What is ado code?
Is it possible to load multiple tables in a Dataset?
What is oledb driver?
What providers does Ado.net uses?
What is difference between ado.net and asp net?
What is datasource in ado.net?
What is difference between datatable and dataset?
What is the usage of the dataset object in ado.net?
What are the usages of the command object in ado.net?
What are the steps you will take to improve performance?
What is aggregating data ?
How can we serialize the dataset object?