Buy @ Amazon

Search This Blog

October 21, 2011

SQL Logging in Rails Console IRB

In order to quickly find the SQL queries that are fired against the DB, while you are playing on the Rails Console, all you need to do is set ActiveRecord's Logger to STDOUT as below:

>>ActiveRecord::Base.logger =

No comments:

Post a Comment

Like it or hate it, feel free to share your feedback. Cheers!