Skip to content
Browse files

Merge pull request #9194 from kwstannard/2-3-stable

Docs: Fixed bad exists? documentation.
  • Loading branch information...
2 parents c774a46 + d61f83d commit 2e4aa39ee6cd56b8d544fda01670f5a48548f13e @fxn fxn committed Feb 6, 2013
Showing with 3 additions and 2 deletions.
  1. +3 −2 railties/guides/source/active_record_querying.textile
5 railties/guides/source/active_record_querying.textile
@@ -867,10 +867,11 @@ Client.exists?(1,2,3)
-Further more, +exists+ takes a +conditions+ option much like find:
+Further more, +exists+ takes a hash or array like what you would pass into a +conditions+ option:
-Client.exists?(:conditions => "first_name = 'Ryan'")
+Client.exists?(:first_name => 'Ryan')
+Client.exists?(['first_name = ?', 'Ryan'])
It's even possible to use +exists?+ without any arguments:

0 comments on commit 2e4aa39

Please sign in to comment.
Something went wrong with that request. Please try again.