ERROR: no driver for sqlite3 found (Ruby 1.9.0 + Windows)

N

nachocab

Hi everyone,
I'm getting this error after I upgraded Ruby from 1.8 to 1.9.0 and
it's driving me crazy:
"no driver for sqlite3 found"

If I do an irb:
irb(main):001:0> require 'sqlite3'
=> true
irb(main):002:0> SQLite3::Database.new( 'my_database.sqlite3' )
RuntimeError: no driver for sqlite3 found
from c:/ruby/lib/ruby/gems/1.9.0/gems/sqlite3-ruby-1.2.3-x86-
mswin32/lib/sqlite3/database.rb:621:in `load_driver'
from c:/ruby/lib/ruby/gems/1.9.0/gems/sqlite3-ruby-1.2.3-x86-
mswin32/lib/sqlite3/database.rb:74:in `initialize'

My path includes:
c:\ruby\bin
And in that directory I have:
sqlite3.exe
sqlite3.dll
sqlite3.def

which I downloaded from the sqlite page: http://www.sqlite.org/download.html
(two files with version 3.6.7)

Also, my webrick loads without a problem. So, what am I doing wrong?
Are there any other windows users who have upgraded to 1.9?

Thanks a lot,

Nacho
 
R

Roger Pack

Nacho said:
Hi everyone,
I'm getting this error after I upgraded Ruby from 1.8 to 1.9.0 and
it's driving me crazy:
"no driver for sqlite3 found"

If I do an irb:
irb(main):001:0> require 'sqlite3'
=> true
irb(main):002:0> SQLite3::Database.new( 'my_database.sqlite3' )
RuntimeError: no driver for sqlite3 found
from c:/ruby/lib/ruby/gems/1.9.0/gems/sqlite3-ruby-1.2.3-x86-
mswin32/lib/sqlite3/database.rb:621:in `load_driver'
from c:/ruby/lib/ruby/gems/1.9.0/gems/sqlite3-ruby-1.2.3-x86-
mswin32/lib/sqlite3/database.rb:74:in `initialize'

you need gem install sqlite3-ruby
Might not be available yet with 1.9 that's on the edge :)
-=R
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top