[Last Call] Learn how to a build a cloud-first strategyRegister Now


installing ruby on rails - `require': no such file to load -- sqlite3/sqlite3_native (LoadError)

Posted on 2011-04-23
Medium Priority
Last Modified: 2012-05-11
Trying to get ruby on rails 1.8.7 working on windows but when i start rails server i get this error:

`require': no such file to load -- sqlite3/sqlite3_native (LoadError)

I have tried copying the 3 sqlite files and putting them in ruby/bin but it doesnt help as mentioned at the bottom of this post: http://www.ruby-forum.com/topic/216270

Any ideas?

Rails 3.0.6 | Ruby 1.8.7 | Windows 7
Question by:Mark Steggles
  • 3
  • 2

Expert Comment

ID: 35452743
Have you installed the sqlite3 gem with "gem install sqlite3-ruby"? I actually don't have any experience running Rails on Windows, but I always almost forget to do this when setting up the Rails development environment on a new machine.
LVL 12

Expert Comment

ID: 35452759
If you're on Rails 3, then all you should need do is
1. add it to your Gemfile
   gem 'sqlite3', '1.3.3', :require => 'sqlite3'
(I have the version number because I don't want random upgrades on my gems)
2. run
  bundle install
and it will take care of installing it for you.

Bundler is your friend when it comes to gems...
LVL 30

Author Comment

by:Mark Steggles
ID: 35452980

I tried that and I get the same error. See attached screen shot

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 12

Expert Comment

ID: 35453207
Ah, windows... Try this point (a bit old, but looks reasonable) http://blog.emson.co.uk/2008/06/installing-sqlite3-on-windows-for-rails/

Or this one which is specific to Rails3: http://accidentaltechnologist.com/ruby-on-rails/running-rails-3-on-windows/
LVL 30

Accepted Solution

Mark Steggles earned 0 total points
ID: 35453311
Found the solution on this post's comments http://www.shaunambrose.com/2010/08/05/how-to-fix-a-sqlite3-dll-missing-error-message-in-ruby-on-rails/comment-page-1/#comment-15965

"The problem seems to be that the sqlite3 gem is compiled with version 3.7.3. I downloaded and set up version 3.7.3 instead and it now works just fine."

Get it here: http://www.sqlite.org/sqlitedll-3_7_3.zip
LVL 30

Author Closing Comment

by:Mark Steggles
ID: 35481738
Found my own answer

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Ruby, Call or invoke a API DLL library is easily via Win32API class, win32-api gem or other gems. For general DLL API call, there are quite a few references, some good tips list below: http://www.rubytips.org/2008/05/13/accessing-windows-api-fro…
Recently I spent hours debugging an issue in a Rails project where ActiveRecord was causing MySQL errors trying to create a User object of a class at the top level of a Single Table Inheritance model structure.  It turns out `.create` behaves differ…
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses
Course of the Month17 days, 17 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question