Skip to content

Commit

Permalink
Add primary key to selectors table in resource groups database
Browse files Browse the repository at this point in the history
Some databases like Percona XtraDB Cluster prohibit inserts into tables
without primary keys. This change also makes this table consistent with
other tables in the resource groups database.
  • Loading branch information
zhangbutao authored and hashhar committed Feb 23, 2022
1 parent 173402e commit 93bfb11
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ALTER TABLE selectors ADD id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY;
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ALTER TABLE selectors ADD id NUMBER GENERATED ALWAYS as IDENTITY(START with 1 INCREMENT by 1) PRIMARY KEY;
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ALTER TABLE selectors ADD COLUMN id BIGSERIAL PRIMARY KEY;

0 comments on commit 93bfb11

Please sign in to comment.