Forum: Ruby on Rails Saving Without Validation

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
John K. (Guest)
on 2007-06-16 20:13
(Received via mailing list)
How do you save a model without validation?  In my migration I want to
make a change to every row in a model but validation rules have
evolved over time and some of the older records are not validating...
argh...

Any suggestions? :-)

--
John K.
removed_email_address@domain.invalid

http://www.kopanas.com
http://www.cusec.net
http://www.soen.info
Bill W. (Guest)
on 2007-06-16 20:29
(Received via mailing list)
Hi John,

John K. wrote:

> How do you save a model without validation?

object.save_with_validation(false)

Best regards,
Bill
This topic is locked and can not be replied to.