Can you use SQLite with ruby outside rails ?
This looks like the installation of sqlite-ruby was not succesfull and
ruby cannot find the required library.
On 4/26/05, Carl Youngblood
<carlwork-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> I have an app that seems to run fine when I develop on windows, but in
> my linux deployment environment I get this error:
>
> uninitialized constant SQLite
>
> Here is the stack trace:
>
>
/usr/lib/ruby/gems/1.8/gems/activesupport-1.0.4/lib/active_support/dependencies.rb:183:in
> `const_missing''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/connection_adapters/sqlite_adapter.rb:33:in
> `sqlite_connection''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/connection_adapters/abstract_adapter.rb:136:in
> `send''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/connection_adapters/abstract_adapter.rb:136:in
> `connection=''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/connection_adapters/abstract_adapter.rb:100:in
> `retrieve_connection''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:235:in
> `connection''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:614:in
> `columns''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:619:in
> `columns_hash''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:636:in
> `column_methods_hash''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:788:in
> `method_missing''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:788:in
> `each''
>
/usr/lib/ruby/gems/1.8/gems/activerecord-1.10.1/lib/active_record/base.rb:788:in
> `method_missing''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/base.rb:708:in
> `send''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/base.rb:708:in
> `perform_action_without_filters''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/filters.rb:294:in
> `perform_action_without_benchmark''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/benchmarking.rb:37:in
> `perform_action_without_rescue''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/benchmarking.rb:37:in
> `measure''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/benchmarking.rb:37:in
> `perform_action_without_rescue''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/rescue.rb:79:in
> `perform_action''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/base.rb:330:in
> `send''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/base.rb:330:in
> `process''
>
/usr/lib/ruby/gems/1.8/gems/actionpack-1.8.1/lib/action_controller/base.rb:273:in
> `process''
> /usr/lib/ruby/gems/1.8/gems/rails-0.12.1/lib/dispatcher.rb:32:in
`dispatch''
> /home/www/exsec.ycs.biz/public/dispatch.fcgi:20
> /home/www/exsec.ycs.biz/public/dispatch.fcgi:18:in `each_cgi''
> /usr/lib/ruby/1.8/fcgi.rb:597:in `each''
> /usr/lib/ruby/1.8/fcgi.rb:597:in `each_cgi''
> /home/www/exsec.ycs.biz/public/dispatch.fcgi:18
>
> I have sqlite-ruby installed; however, in my deployment environment it
> is not installed as a gem, which is different from my development
> environment. I know this is not a lot to go on, but I was wondering
> if anyone knows off-hand if this is a common bug that has a known fix.
>
> Thanks,
>
> Carl Youngblood
> _______________________________________________
> Rails mailing list
> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
--
// heikki tunkelo