# SQLite3 error

**URL:** <https://www.ruby-forum.com/t/sqlite3-error/134126>\
**Category:** Rails\
**Created:** [April 8, 2008, 4:49am UTC](https://www.ruby-forum.com/t/sqlite3-error/134126 "2008-04-08T04:49:36Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 4:49am UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/1 "2008-04-08T04:49:36Z")

</div>

I am trying to install SQLite3 on my Rails app but I keep getting this  
error:

./sqlite3.dll: 127: The specified procedure could not be found. â€“  
Init\_sqlite3 (LoadError)

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 1:37pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/2 "2008-04-08T13:37:19Z")

</div>

On Mon, Apr 7, 2008 at 10:49 PM, Matt Murphy  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I am trying to install SQLite3 on my Rails app but I keep getting this  
> error:
> 
> ## ./sqlite3.dll: 127: The specified procedure could not be found. - Init\_sqlite3 (LoadError)

Did you install sqlite3 (from [SQLite Download Page](http://www.sqlite.org/download.html)) in  
addition to the sqlite3-ruby gem?

–wpd

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 2:06pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/3 "2008-04-08T14:06:26Z")

</div>

I downloaded both the SQLite3.exe, SQLite3.def, and SQLite3.dll files  
and placed them in my Ruby path directory: C:\ruby\bin if that’s what  
you mean.

I have the same issue for both v3.5.7 and 3.5.4

The gem install sqlite3-ruby works fine.

Matt

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 3:34pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/4 "2008-04-08T15:34:34Z")

</div>

OK, I think I found out what was wrong. I installed the gem before I  
placed the dll, exe and def files into my ruby bin directory.

Thanks,  
Matt

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 2:14pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/5 "2008-04-08T14:14:37Z")

</div>

Matt Murphy wrote:

> I downloaded both the SQLite3.exe, SQLite3.def, and SQLite3.dll files  
> and placed them in my Ruby path directory: C:\ruby\bin if that’s what  
> you mean.
> 
> I have the same issue for both v3.5.7 and 3.5.4
> 
> The gem install sqlite3-ruby works fine.
> 
> Matt

Also when I run this command:  
“c:\ruby\bin\ruby.exe” “c:\ruby\bin\gem” install sqlite3

as seen in step 2 with windows here:  
[http://wiki.rubyonrails.org/rails/pages/HowtoUseSQLite](http://wiki.rubyonrails.org/rails/pages/HowtoUseSQLite)

I get this error message:  
ERROR: could not find sqlite3 locally or in a repository

Matt

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 5:53pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/6 "2008-04-08T17:53:45Z")

</div>

Here’s something interesting, it will work if I load up the app normally  
(ie start webrick) however if I package the app using tar2rubyscript and  
it becomes a single .rb file, when loading that up, I get the error…

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 8, 2008, 5:39pm UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/7 "2008-04-08T17:39:23Z")

</div>

Matt Murphy wrote:

> OK, I think I found out what was wrong. I installed the gem before I  
> placed the dll, exe and def files into my ruby bin directory.
> 
> Thanks,  
> Matt

Nevermind, damned error came back again.

127: The specified procedure could not be found. - Init\_sqlite3  
C:/…/app/sqlite3.dll

.  
.  
.

This error occurred while loading the following files:  
sqlite3

---

<div class="post-metadata">

**Author:** ![mattmcswain](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ecb155/32.png) [@mattmcswain](https://www.ruby-forum.com/u/mattmcswain)\
**Post date:** [April 9, 2008, 3:13am UTC](https://www.ruby-forum.com/t/sqlite3-error/134126/8 "2008-04-09T03:13:14Z")

</div>

Matt Murphy wrote:

> Here’s something interesting, it will work if I load up the app normally  
> (ie start webrick) however if I package the app using tar2rubyscript and  
> it becomes a single .rb file, when loading that up, I get the error…

Problem resolved. Had to upgrade to the newest versions of Ruby 1.8.6,  
Ruby Gems 1.1.0, & Rails 2.0.2 (with SQLite 3.5.7)

[http://www.matts411.com/webdev/ruby\_on\_rails\_standalone\_how\_to](http://www.matts411.com/webdev/ruby_on_rails_standalone_how_to)
