Sqlite 3 error

I have installed Ruby on Rails .
rails -v=>3.0.7
gem -v=>1.3.6
ruby -v=>ruby 1.8.7 (2010-01-10 patchlevel 249) [i486-linux]

                         when i tried to start the server by "rails 

s"
or tried to do anything it gives the error

Could not find gem ‘sqlite3 (>= 0, runtime)’ in any of the gem sources
listed in your Gemfile.
Run bundle install to install missing gems.

Please somebody help me to get rid of it…:stuck_out_tongue:

Thanks in advance

amritpalpathakgne.wordpress.com

Do, what it says… run ‘bundle install’ on your app.
Or manually install sqlite3 gem

Hi,

If you r using ubuntu machine means, you can try to install the below
packages…

sudo apt-get install sqlite3 libsqlite3-dev

gem install sqlite3-ruby

This is the Solution for your problem.

Regards,
Mathew vivek

On Mon, Jun 27, 2011 at 4:33 AM, Chirag S.
[email protected]wrote:

Do, what it says… run ‘bundle install’ on your app.
Or manually install sqlite3 gem

    I tried "bundle install" from app.I couldn't work too.error

persists.

thanks

Hi,

first you need to install sqlite3.
In Ubuntu: sudo apt-get install libsqlite3-dev

Second install the sqlite gem
gem install sqlite3-ruby

see here for example

I am not sure if rails 3 works with ruby 1.8.7 but I would recommend
you to switch to version 1.9.2 anyway

On Mon, Jun 27, 2011 at 4:16 AM, Kevin [email protected] wrote:

I am not sure if rails 3 works with ruby 1.8.7 but I would recommend
you to switch to version 1.9.2 anyway

It worked.

Thank you very much.

          one thing left .now i can start old rail app but it gives 

the
error of rake when i did “rake db:create”

rake aborted!
You have already activated rake 0.9.2, but your Gemfile requires rake
0.8.7.
Consider using bundle exec.

(See full trace by running task with --trace)

thanks

Teri you are right, ruby 1.8.7 works fine.

You can check with “gem list” which gems are installed. Probably you
have a newer version installed (0.9.2) as required in your Gemfile
(0.8.7).
So try running “bundle exec rake” instead of just rake.
See here for example:

I encourage you to use the ruby version manager. It enables you to
switch between different gem sets really easy and you can install
different gem versions for different projects.

On Jun 27, 2011, at 1:16, Kevin wrote:

I am not sure if rails 3 works with ruby 1.8.7 but I would recommend
you to switch to version 1.9.2 anyway

Rails 3 and even 3.1.0rc4 work fine with ruby 1.8.7.

Make sure the place you will eventually deploy to supports Ruby 1.9.2
before switching. I just had to downgrade to deploy to Dreamhost because
their passenger won’t work with anything but 1.8.7.


Teri S.
http://tekniklr.com

Hi,

try

gem install sqlite3,

or

try this mysql db

rails my_new_app --database=mysql

Cheers,
Sai

On Mon, Jun 27, 2011 at 12:47 PM, amritpal pathak
<[email protected]