1 # Copyright (C) The Arvados Authors. All rights reserved.
3 # SPDX-License-Identifier: AGPL-3.0
5 class TimestampsNotNull < ActiveRecord::Migration[4.2]
7 ActiveRecord::Base.connection.tables.each do |t|
8 next if t == 'schema_migrations'
9 change_column t.to_sym, :created_at, :datetime, :null => false
10 change_column t.to_sym, :updated_at, :datetime, :null => false
14 # There might have been a NULL constraint before this, depending
15 # on the version of Rails used to build the database.