-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: SQLiteDriver problem
PostPosted: Wed Apr 19, 2006 5:14 am 
Newbie

Joined: Wed Apr 19, 2006 5:09 am
Posts: 2
Hey all,

I'm new to the NHibernate system, yet I already have a problem:
I keep getting the "Could not create the driver from NHibernate.Driver.SQLiteDriver" error message.

This is a copy of my config file

Code:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <configSections>
    <section
      name="nhibernate"
      type="System.Configuration.NameValueSectionHandler, System, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
    />
  </configSections>

  <nhibernate>
    <add
      key="hibernate.dialect"
      value="NHibernate.Dialect.SQLiteDialect"
    />

    <add
      key="hibernate.connection.provider"
      value="NHibernate.Connection.DriverConnectionProvider"
    />

   <add
     key="hibernate.connection.driver_class"
      value="NHibernate.Driver.SQLiteDriver"
    />

   <add
     key="hibernate.connection.connection_string"
      value="Data Source=nhibernate.db;Version=3"
    />

   <add
     key="hibernate.query.substitutions"
      value="true=1;false=0"
    />
  </nhibernate>
</configuration>


Now whenever the compilation reaches this point:
Code:
Configuration cfg = new Configuration();
cfg.AddAssembly("NHibernate");
-----> ISessionFactory factory = cfg.BuildSessionFactory(); <-----
ISession session = factory.OpenSession();
ITransaction transaction = session.BeginTransaction();
session.Close();

it pops up the error message.

Can someone help me out pls?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 19, 2006 9:32 pm 
Newbie

Joined: Tue Oct 18, 2005 10:28 pm
Posts: 3
Location: Melbourne - Australia
Hello DenAcied,

Have a look at the inner-exceptions, I had similar problem when using MySQL and just following the trail of inner exceptions gave me enough info to resolve the issue.

Hope this helps.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.