what is the syntax code for oldb to connect oracle

Answers were Sorted based on User's Feedback



what is the syntax code for oldb to connect oracle..

Answer / srinivas.kinthada

i think oldb is not correct it's may b.
it is oledb

using system.data.oledb;
oledbconnection cn=new
oledbconnection("uid=<username>;pwd=<password>;server=<servername>");
cn.open();

Is This Answer Correct ?    2 Yes 0 No

what is the syntax code for oldb to connect oracle..

Answer / raghavendra.v

it is not oldb it may be oledb

using System.Data.Oledb;

Oledbconnection cn=new OleDbConnection
("Provider=Msdaora.1;uid=<username>;pwd=<pwd>;server=<server
name>");
cn.open();

Is This Answer Correct ?    1 Yes 1 No

what is the syntax code for oldb to connect oracle..

Answer / sudha

first add the namespace

using system.Data.oledb;

OledbConnection cntn = new OledbConnection("Provider =
Microsoft.jet.oledb.12.0;datasource = (local);Integrated
security = SSPI,persistent Security = false");

provider = it depends on version of Microsoft Access like if
it is 2003 - 4.0 & if it is 2007 - 12.0

dataource - u can make it as local or provide the path to ur
database

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More ADO.NET Interview Questions

What is isolation?

0 Answers  


What is executequery?

0 Answers  


What is the executescalar method?

0 Answers  


Define executenonquery?

0 Answers  


What is difference between dataset and datatable?

0 Answers  


If a table contains 20000 records . In a page at each time 100 records to be displayed what are the steps you will take to improve performance? Will you use dataset or datareader?

0 Answers  


Being fresher How would i answer to the question that what is your salary exception?

4 Answers  


what is ado.net

6 Answers   Karrox, SunGard,


What is ole db and odbc?

0 Answers  


How to check if the Dataset has records ?

0 Answers   NA,


Explain how can we load multiple tables in to dataset?

0 Answers  


Which method is used by command class to execute SQL statements that return single value?

0 Answers  


Categories