If your MySQL server is not on localhost, you probably should connect
via a hostname and a port number (usually 3306), not by specifying a
socket, just like in any other environment. Read the comments in the
database.yml, which gives an example.
Look at how you connect to that MySQL server from your machine with
other tools. Those are the settings you should use.
However, you may be happiest developing with a local database so you can
work without a net connection at all if need be.
Neil Bate wrote:
Hi this is my first time with Rails and I’m having problems getting it
to work properly. In the Database.yml file I have set up the following -
But, when I launch the controler it says -
NameError in Add_car#index
uninitialized constant Car
Where am I going wrong, as the database is not on localhost is there
anything wrong in what I have done?