Ask A Question

Notifications

You’re not receiving notifications from this thread.

Connect Rails Application to already existing MySql Database

Rishabh Shukla asked in Databases
Hi there, I am new to Rails and really enjoying it. 
I am converting my php application to a ROR application. The app is using a MySql DB, so I want to connect the ROR application with that already created DB and want to preserve the data. php has mysqli functions, does ROR has anything similar to that ?

Help appreciated. Warm Regards.
Reply
Depending on wether you want to keep running the PHP app. If you don't, read into ActiveRecord, create your models and then write a few migrations to make sure the columns and indexes do match the naming conventions in Rails.
Reply
Join the discussion
Create an account Log in

Want to stay up-to-date with Ruby on Rails?

Join 86,946+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.