Re: Enterprise Library January 2006 Data Access Application Block and Oracle

"Smotritsky, Alex" <[email protected]>
Newsgroups gmane.comp.windows.devel.dotnet.web
Message-ID <[email protected]>
I've made some progress.

I did this:

http://www.shinstudio.com/sh.kim/?p=108

and now I get this error:

ORA-12154: TNS:could not resolve service name


-----Original Message-----
From: Discussion of building .NET applications targeted for the Web
[mailto:[email protected]] On Behalf Of Smotritsky, Alex
Sent: Friday, April 06, 2007 12:00 PM
To: [email protected]
Subject: [DOTNET-WEB] Enterprise Library January 2006 Data Access
Application Block and Oracle

I have this code connecting to the db and trying to get a dataset:



//Connect to the datase specified

Database db =
DatabaseFactory.CreateDatabase(this.DefaultDatabase.DatabaseName);



System.Data.Common.DbCommand dbCommand =
db.GetSqlStringCommand(sqlquery);



//Enterprise library call to execute SQL Query specified

return db.ExecuteDataSet(dbCommand);



The last line throws an exception with message:



System.Data.OracleClient requires Oracle client software version 8.1.7
or greater.



I think the problem is what I currently have in Web.Config which is:



<configSections>

<section name="dataConfiguration"
type="Microsoft.Practices.EnterpriseLibrary.Data.Configuration.DatabaseS
ettings, Microsoft.Practices.EnterpriseLibrary.Data, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=null" />

      <section name="oracleConnectionSettings"
type="Microsoft.Practices.EnterpriseLibrary.Data.Oracle.Configuration.Or
acleConnectionSettings,    Microsoft.Practices.EnterpriseLibrary.Data,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=null" />

</configSections>



<connectionStrings>

      <add name="GAP"

            connectionString="server=bla.bla.bla;uid=bla;pwd=bla;"

            providerName="System.Data.OracleClient"/>

</connectionStrings>



Any thoughts on this or how to connect to oracle with this version of
the enterprise library and asp.net 2.0 in general?






===================================
This list is hosted by DevelopMentor(r)  http://www.develop.com

View archives and manage your subscription(s) at
http://discuss.develop.com

===================================
This list is hosted by DevelopMentor®  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.