Hello,
I''m trying to use a delete_all method to kill some information in my
database. Where my model is ''prov'', my code is:
Prov.delete_all(["created_at < ?",
@currenttime],["bill_cycle_date =?", @cycle_date])
Basically the equivalent to the SQL statement:
DELETE FROM provs
WHERE created_at < @currenttime AND bill_cycle_date = @cycle_date
However, the first bit doesn''t work and it tells me that it is the
incorrect number of arguments. Can somebody please clarify how to do
this?
Thanks,
- Jeff Miller
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
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
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---