John Butler
2008-Feb-12 09:43 UTC
Validate all model fields with validates_numericality_of
hi, I have a rather big table and i need to validate every decimal field in the table to make sure its numeric. Can anyone think of the best way to do this or is it even possible? I dont want to write validates_numericality_of: and then each field in the table seperately. JB -- 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 -~----------~----~----~----~------~----~------~--~---
Possibly Parallel Threads
- validates_numericality_of :not_equal_to
- At my wits end ! Controlling passed in negative values from a form
- validates_numericality_of and greater_than* doesn't appear to be working
- ActiveRecord: When / where to validate data? Tricky question
- validates_numericality_of positive integer