Skip to content

Commit

Permalink
mysql: convert invalid dates to nil
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardochimal committed Mar 27, 2010
1 parent 1541b1f commit 0b20485
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/taps/data_stream.rb
Expand Up @@ -199,6 +199,10 @@ def import_rows(rows)
end

def self.factory(db, state)
if db.class.to_s == "Sequel::MySQL::Database"
Sequel::MySQL.convert_invalid_date_time = :nil
end

if state.has_key?(:klass)
return eval(state[:klass]).new(db, state)
end
Expand Down

0 comments on commit 0b20485

Please sign in to comment.