mirror of
https://github.com/openziti/zrok.git
synced 2024-11-07 08:44:14 +01:00
remove unique constraint on email to accomodate soft deletes
This commit is contained in:
parent
edef86d06a
commit
85616370fc
@ -0,0 +1,3 @@
|
||||
-- +migrate Up
|
||||
|
||||
ALTER TABLE account_requests DROP CONSTRAINT account_requests_email_key;
|
@ -0,0 +1,15 @@
|
||||
-- +migrate Up
|
||||
|
||||
alter table account_requests rename to account_requests_old;
|
||||
create table account_requests (
|
||||
id integer primary key,
|
||||
token string not null unique,
|
||||
email string not null,
|
||||
source_address string not null,
|
||||
created_at datetime not null default(strftime('%Y-%m-%d %H:%M:%f', 'now')),
|
||||
updated_at datetime not null default(strftime('%Y-%m-%d %H:%M:%f', 'now')),
|
||||
deleted boolean not null default(false)
|
||||
);
|
||||
|
||||
insert into account_requests select * from account_requests_old;
|
||||
drop table account_requests_old;
|
Loading…
Reference in New Issue
Block a user