Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rails - See generated SQL queries in Log files

Is there a way to see all generated queries from rails in production environment like you can in development?

like image 702
tybro0103 Avatar asked Oct 04 '10 04:10

tybro0103


1 Answers

Yes you can. If you go in the config/environments/production.rb file, there's a section like this:

# See everything in the log (default is :info)
# config.log_level = :debug

Uncomment the config.log_level line, and you'll get the same log in production as you would in dev.

like image 124
pushmatrix Avatar answered Nov 18 '22 23:11

pushmatrix