The issue could be with a x86, x64 mismatch. Are you using Win7 x64? I'm using the same version of the Oracle client and set the Build -> Platform Target: -> x86.
That works. On May 12, 10:20 am, c24chan <[email protected]> wrote: > Hi all, > > Running into a problem with oracle data client on window 7. > > The version of Oracle.DataAccess I am using is 2.111.7.20 and here is > my hibernate.cfg.xml. > > <?xml version="1.0" encoding="utf-8" ?> > <hibernate-configuration xmlns="urn:nhibernate-configuration-2.2"> > <!--<reflection-optimizer use ="true"/> --> > <session-factory> > <property > name="connection.provider">NHibernate.Connection.DriverConnectionProvider</ > property> > <property name="dialect">NHibernate.Dialect.Oracle10gDialect</ > property> > <property > name="connection.driver_class">NHibernate.Driver.OracleDataClientDriver</ > property> > <property name="connection.connection_string"> > User ID=aaa; > Password=aaa; > Pooling=true; > Enlist=false; > Statement Cache Size=50; > Min Pool Size=10; > Incr Pool Size=5; > Decr Pool Size=2; > Data Source=aaa.aaa > </property> > <property name="show_sql">true</property> > <property > name="proxyfactory.factory_class">NHibernate.ByteCode.Castle.ProxyFactoryFactory, > NHibernate.ByteCode.Castle</property> > <property name="prepare_sql">true</property> > <property name="query.substitutions">Y=true,N=false,0=false, > 1=true</property> > <property name="generate_statistics">true</property> > <property name ="cache.use_second_level_cache">true</property> > <property name="cache.use_query_cache">true</property> > > <!-- development--> > <property > name="cache.provider_class">NHibernate.Cache.HashtableCacheProvider</ > property> > <mapping assembly="Core" /> > </session-factory> > </hibernate-configuration> > > When I run my console test app, it is throwing me the following error. > > "Could not create the driver from > NHibernate.Driver.OracleDataClientDriver." > > with stacktrace > > at > NHibernate.Connection.ConnectionProvider.ConfigureDriver(IDictionary`2 > settings) > at NHibernate.Connection.ConnectionProvider.Configure(IDictionary`2 > settings) > at > NHibernate.Connection.ConnectionProviderFactory.NewConnectionProvider(IDictionary`2 > settings) > at NHibernate.Cfg.SettingsFactory.BuildSettings(IDictionary`2 > properties) > at NHibernate.Cfg.Configuration.BuildSettings() > at NHibernate.Cfg.Configuration.BuildSessionFactory() > at Workopolis.ConsoleTest.Program.Main(String[] args) in C: > \Workopolis\Cobra\Main\Source\Workopolis.ConsoleTest\Program.cs:line > 20 > at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] > args) > at > Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() > at System.Threading.ExecutionContext.Run(ExecutionContext > executionContext, ContextCallback callback, Object state) > at System.Threading.ThreadHelper.ThreadStart() > > The kicker is that the same dll and config file works in a web > solution but not a console app, any ideas? > > -- > You received this message because you are subscribed to the Google Groups > "nhusers" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group > athttp://groups.google.com/group/nhusers?hl=en. -- You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
