From 7f023b5e3bd62c1f91ee341c1af155c0953e693a Mon Sep 17 00:00:00 2001 From: Ryan Bigg Date: Wed, 12 Nov 2008 21:45:42 +1030 Subject: Updated finders guide --- railties/doc/guides/source/finders.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/railties/doc/guides/source/finders.txt b/railties/doc/guides/source/finders.txt index 2e6b368e3f..d26711fce2 100644 --- a/railties/doc/guides/source/finders.txt +++ b/railties/doc/guides/source/finders.txt @@ -120,7 +120,7 @@ To find all the clients you would simply type +Client.all+ and that would find a created_at: "2008-09-28 15:38:50", updated_at: "2008-09-28 15:38:50">, # "Michael", locked: false, orders_count: 3, created_at: "2008-09-28 13:12:40", updated_at: "2008-09-28 13:12:40">] -------------------------------------------------------- +------------------------------------------------------- As alternatives to calling +Client.first+, +Client.last+, and +Client.all+, you can use the class methods +Client.first+, +Client.last+, and +Client.all+ instead. +Client.first+, +Client.last+ and +Client.all+ just call their longer counterparts: +Client.find(:first)+, +Client.find(:last)+ and +Client.find(:all)+ respectively. -- cgit v1.2.3