Cloud Computing: The Digital Shift 2.0 – Understanding the Current Market Trends

Awesome: Working with the Rails console and all the tricks

Testing your active record methods using script/console

If you are using windows, you start the console by using this command:

ruby script\console


Just use the following command whenever you make changes to your model objects:


Instead of accessing your MySQL database with

mysql -u -p

You can instead do


and if you database has a password, just do

script/dbconsole -p

% script/dbconsole # connect to development database (or $RAILS_ENV)
% script/dbconsole production # connect to production database

Cheers !


0 thoughts on “Awesome: Working with the Rails console and all the tricks”

Leave a Comment

Your email address will not be published.