mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
ARel -> Arel
This commit is contained in:
parent
2026bb1026
commit
00a805d419
1 changed files with 1 additions and 1 deletions
|
@ -101,7 +101,7 @@ Rails 3.2 comes with a development mode that's noticeably faster. Inspired by [A
|
||||||
|
|
||||||
### Automatic Query Explains
|
### Automatic Query Explains
|
||||||
|
|
||||||
Rails 3.2 comes with a nice feature that explains queries generated by ARel by defining an `explain` method in `ActiveRecord::Relation`. For example, you can run something like `puts Person.active.limit(5).explain` and the query ARel produces is explained. This allows to check for the proper indexes and further optimizations.
|
Rails 3.2 comes with a nice feature that explains queries generated by Arel by defining an `explain` method in `ActiveRecord::Relation`. For example, you can run something like `puts Person.active.limit(5).explain` and the query Arel produces is explained. This allows to check for the proper indexes and further optimizations.
|
||||||
|
|
||||||
Queries that take more than half a second to run are *automatically* explained in the development mode. This threshold, of course, can be changed.
|
Queries that take more than half a second to run are *automatically* explained in the development mode. This threshold, of course, can be changed.
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue