On Monday, August 22, 2016 at 5:08:49 PM UTC-7, John Graziano wrote: > > I'm working with a database that uses zero DateTime strings as nulls > (0000-00-00 00:00:00). Any recommendations on how to load these values > without triggering exceptions from time.rb? >
I'm guessing you are using MySQL. In which case, you should use the mysql adapter (not the mysql2 adapter), and set DB.convert_invalid_date_time = :string Then those invalid values will be returned as strings instead of raising an exception. Another option would be to just switch to using NULL values instead of invalid values. Thanks, Jeremy -- You received this message because you are subscribed to the Google Groups "sequel-talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/sequel-talk. For more options, visit https://groups.google.com/d/optout.
