3

I followed the suggestion here: and the gem seemed to install correctly, but when I ran rake:db:migrate from the windows command line, I got a full on pop up saying:

"This application has failed to start because sqlite3.dll was not found. Re-installing the application may fix this problem"

which is really weird, because normally (when I have no sqlite3), I get a text error in line with the other debug statements on the command line.

I'm installing sqlite3-ruby -v 1.2.3 (but it does the same thing with ANY version of sqlite3 I try to install, now...even the newest one (1.2.5, which has a bunch of "No definition" errors when I try to install it))

Community
  • 1
  • 1
J.R.
  • 5,789
  • 11
  • 55
  • 78

1 Answers1

3

Silly question but: you have installed the sqlite gem but have you installed the sqlite application yet?

The gem is just the way your rails program will talk to the real sqlite application. If you don't have that installed, then there's nothing for it to talk to. I'm guessing that installing sqlite application will install the sqlite3.dll and then it'll all work again.

Taryn East
  • 27,486
  • 9
  • 86
  • 108
  • 2
    Hrrrm...I don't...I don't remember having to actually do that when I was installing rails on a different windows machine. I kind of figured the gem WAS the application (at least as far as ruby was concerned), I mean, what else could it be? I'll do a quick google search, see if there actually is a way to install sqlite 3... Looks like I can go to the sqlite website, and download precompiled binaries for Windows... But this amounts to just having a "sqlite3.exe" file on my desktop, no dlls. Rake still doesn't work. – J.R. Feb 22 '10 at 16:51
  • 5
    Wait, there was a separate "dll" download... Found a website (http://www.skorks.com/2009/08/installing-and-using-sqlite-with-ruby-on-windows/) on this. Put the dlls in the ruby bin folder. It worked!! Thanks! I probably didn't remember installing before because I flailed around a LOT before finally finding out about using a particular gems version. Thanks so much! – J.R. Feb 22 '10 at 16:56
  • De Nada :) It's one of those thing I keep forgetting too (though generally with mysql). – Taryn East Feb 22 '10 at 17:04
  • 2
    you need the sqlite3.dll in your environment path. so yes, you can throw the sqlite.dll file into your windows system32 directory, or you can just add the folder which contains it to your environment path variable. i had the same problem and this worked for me. – Brandon Montgomery Dec 15 '10 at 05:09