Rails 4: Show SQL in console in production
ruby-on-rails, ruby-on-rails-4
Solution
ActiveRecord::Base.logger = Logger.new(STDOUT)
Execute it in rails console on your server, and then all the ActiveRecord generated SQL queries will be shown.
Problem
After upgrading to rails 4 the executed SQL is no longer shown when I execute commands in the rails console on my server in production. How can I enable that again, without hurting the performance?