-- 1523022636 UP change_company_to_id
delete from invoices;

alter table invoices drop column company;
alter table invoices add column company_id integer;
alter table invoices add constraint fk_invoices__company_id foreign key (company_id) references companies(id);
