Fix migration sql for inserting accounting records

Migration SQL could not insert accounting records because datec was set
to NOT NULL