On Sat, Feb 23, 2013 at 8:44 PM, Borna Novak <[email protected]> wrote:

> how does this work with legacy tables that have no PK? What makes them
> possible now is that you can filter down with 'where' onto a single record
> and get .first out without triggering a fetch through ID. Perhaps implement
> an "any" finder method with same function as the old "first" ?

Yep, in Rails 4 the new #take method is the old #first:

    
https://github.com/rails/rails/blob/master/activerecord/lib/active_record/relation/finder_methods.rb#L57-L66

Xavier

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to