Forum: Ruby on Rails problem with mysql in windows

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
khawshik (Guest)
on 2008-11-22 15:08
(Received via mailing list)
I installed ruby186-26
and then run this three command in command line....
gem update --system
gem install rails
gem install mongrel

Now i nedd to install mysql and i wish to working with mysql.

but my database.ymal have this kind of think

database.yml

# SQLite version 3.x
#   gem install sqlite3-ruby (not necessary on OS X Leopard)
development:
  adapter: sqlite3
  database: db/development.sqlite3
  timeout: 5000

# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
test:
  adapter: sqlite3
  database: db/test.sqlite3
  timeout: 5000

production:
  adapter: sqlite3
  database: db/production.sqlite3
  timeout: 5000



...................................................................................................................................



i am working with php so i have mysql 5 installed on my computer and
also apache

sqlite is better but i am flexible with mysql ..............

last few days i tried hard for enabling mysql instead of sqlite but

there is a plenty of problem..................

can anyone help me please..........................
i want help for working with mysql.........................
Can anyone help about the total mysql installation process in ruby and
connecting to database.
Ashwin Mangale (Guest)
on 2008-11-22 16:44
(Received via mailing list)
Hi,
  Even if you have mysql installed you will need to get the mysql
adapter written in C for rails. By default, rails ships with the
adapter written in ruby. To do this , just execute ' gem install mysql
'.

Now, for your rails application to use mysql db instead of the default
sqlite3, use the following command,
  ' rails <app_name> -d mysql '

This will configure the rails app to use mysql instead of sqlite3. You
can verify this by checking the 'database.yml' file once the app is
created.

Hope this helps.

Regards,
Ashwin
This topic is locked and can not be replied to.