Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed a slightly misleading equivalent SQL code on the 3.2 query inte…

…rface.
  • Loading branch information...
commit 30feb8c816a7314b69530bf383d6cacce4a602c2 1 parent 1f2224d
@swanandp swanandp authored vijaydev committed
Showing with 1 addition and 1 deletion.
  1. +1 −1  railties/guides/source/active_record_querying.textile
View
2  railties/guides/source/active_record_querying.textile
@@ -94,7 +94,7 @@ client = Client.find(10)
The SQL equivalent of the above is:
<sql>
-SELECT * FROM clients WHERE (clients.id = 10)
+SELECT * FROM clients WHERE (clients.id = 10) LIMIT 1
</sql>
<tt>Model.find(primary_key)</tt> will raise an +ActiveRecord::RecordNotFound+ exception if no matching record is found.
Please sign in to comment.
Something went wrong with that request. Please try again.