System.Data.EntityException while query
Posted: Thu 16 Jul 2009 15:04
Hi,
I am evaluating dotConnect oracle provider for my project with Oracle 9i (ver 9.2.0. and Oracle 10g.
I have tested code with Oracle 10 and 9i. The code works fine with Oracle 10g and when I change connection string from connecting to Oralce 9i then i get exception :
System.Data.EntityException] = {"The underlying provider failed on Open."}
I get this exception while executing query.
Can you help me to understand what is the issue.
I am pasting connection string I am using:
Connection string inside app.config which was generated while generating entity model from database.
Oracle 10g:
public static string getConStrIntegrated()
{
string conStrIntegratedSecurity = new System.Data.EntityClient.EntityConnectionStringBuilder
{
Metadata = "res://*/Model.csdl|res://*/Model.ssdl|res://*/Model.msl",
Provider = "Devart.Data.Oracle",
//Provider = "DDTek.Oracle",
ProviderConnectionString = new System.Data.SqlClient.SqlConnectionStringBuilder
{
// User Id=hr;Password=manager;Server=XE;Persist Security Info=True
//InitialCatalog = "Northwind",
DataSource = "XE",
UserID = "hr",
Password = "manager",
}.ConnectionString
}.ConnectionString;
return conStrIntegratedSecurity;
}
and Oracle 9i:
public static string getConStrIntegrated()
{
string conStrIntegratedSecurity = new System.Data.EntityClient.EntityConnectionStringBuilder
{
Metadata = "res://*/Model.csdl|res://*/Model.ssdl|res://*/Model.msl",
Provider = "Devart.Data.Oracle",
//Provider = "DDTek.Oracle",
ProviderConnectionString = new System.Data.SqlClient.SqlConnectionStringBuilder
{
// User Id=hr;Password=manager;Server=XE;Persist Security Info=True
//InitialCatalog = "Northwind",
DataSource = "ANIL",
UserID = "hr",
Password = "manager",
}.ConnectionString
}.ConnectionString;
return conStrIntegratedSecurity;
}
Code works with Oracle 10g but same code doesn't work with Oracle 9i.
Can you please help in this I need to decide provider for the project.?
Do you have any phone number where i can reach out for further queries?
Thanks,
Anil
I am evaluating dotConnect oracle provider for my project with Oracle 9i (ver 9.2.0. and Oracle 10g.
I have tested code with Oracle 10 and 9i. The code works fine with Oracle 10g and when I change connection string from connecting to Oralce 9i then i get exception :
System.Data.EntityException] = {"The underlying provider failed on Open."}
I get this exception while executing query.
Can you help me to understand what is the issue.
I am pasting connection string I am using:
Connection string inside app.config which was generated while generating entity model from database.
Oracle 10g:
public static string getConStrIntegrated()
{
string conStrIntegratedSecurity = new System.Data.EntityClient.EntityConnectionStringBuilder
{
Metadata = "res://*/Model.csdl|res://*/Model.ssdl|res://*/Model.msl",
Provider = "Devart.Data.Oracle",
//Provider = "DDTek.Oracle",
ProviderConnectionString = new System.Data.SqlClient.SqlConnectionStringBuilder
{
// User Id=hr;Password=manager;Server=XE;Persist Security Info=True
//InitialCatalog = "Northwind",
DataSource = "XE",
UserID = "hr",
Password = "manager",
}.ConnectionString
}.ConnectionString;
return conStrIntegratedSecurity;
}
and Oracle 9i:
public static string getConStrIntegrated()
{
string conStrIntegratedSecurity = new System.Data.EntityClient.EntityConnectionStringBuilder
{
Metadata = "res://*/Model.csdl|res://*/Model.ssdl|res://*/Model.msl",
Provider = "Devart.Data.Oracle",
//Provider = "DDTek.Oracle",
ProviderConnectionString = new System.Data.SqlClient.SqlConnectionStringBuilder
{
// User Id=hr;Password=manager;Server=XE;Persist Security Info=True
//InitialCatalog = "Northwind",
DataSource = "ANIL",
UserID = "hr",
Password = "manager",
}.ConnectionString
}.ConnectionString;
return conStrIntegratedSecurity;
}
Code works with Oracle 10g but same code doesn't work with Oracle 9i.
Can you please help in this I need to decide provider for the project.?
Do you have any phone number where i can reach out for further queries?
Thanks,
Anil