hydra/src/sql/upgrade-81.sql
2022-01-31 12:56:34 -08:00

6 lines
333 B
SQL

alter table runcommandlogs add column uuid uuid;
update runcommandlogs set uuid = gen_random_uuid() where uuid is null;
alter table runcommandlogs alter column uuid set not null;
alter table runcommandlogs add constraint RunCommandLogs_uuid_unique unique(uuid);
create index IndexRunCommandLogsOnBuildID on RunCommandLogs(build_id);