Hi there Morgan, Something such as the following should do the trick: Article.count(:conditions => "status = 'active'")
HTH, Schalk Morgan Morgan wrote: > so i have a database filled with stats and i need to return a number > from those stats for processing. how would i go about counting how many > of a certian thing there are in a particular column.. > > example: say i wanted to see how many records showed female in the users > table but i didn't actually want to pull a bunch of info, i just want > the number returned. > > thanks.. i hope this makes sense. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
begin:vcard fn:Schalk Neethling n:Neethling;Schalk org:Overt Strategy Consulting adr:Florauna;;Berg ave 642;Pretoria;Gauteng;0182;South Africa email;internet:[email protected] title:President tel;work:+27125468436 x-mozilla-html:FALSE url:http://www.overtstrategyconsulting.com version:2.1 end:vcard

