Skip to content

Commit

Permalink
Rename controllers.admin_user column to admin_identity_name
Browse files Browse the repository at this point in the history
Signed-off-by: Babak K. Shandiz <[email protected]>
  • Loading branch information
babakks committed Jan 17, 2024
1 parent 77a2eae commit 418a569
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions internal/dbmodel/sql/postgres/1_6.sql
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ ALTER TABLE IF EXISTS models RENAME COLUMN owner_username TO owner_identity_name
ALTER TABLE IF EXISTS application_offer_connections RENAME COLUMN username TO identity_name;
ALTER TABLE IF EXISTS user_model_defaults RENAME TO identity_model_defaults;
ALTER TABLE IF EXISTS identity_model_defaults RENAME COLUMN username TO identity_name;
ALTER TABLE IF EXISTS controllers RENAME COLUMN admin_user TO admin_identity_name;
ALTER TABLE IF EXISTS audit_log RENAME COLUMN user_tag TO identity_tag;

-- Renaming indexes:
Expand All @@ -27,9 +28,6 @@ ALTER INDEX IF EXISTS cloud_credentials_cloud_name_owner_username_name_key RENAM
ALTER INDEX IF EXISTS cloud_defaults_username_cloud_id_region_key RENAME TO cloud_defaults_identity_name_cloud_id_region_key;
ALTER INDEX IF EXISTS idx_audit_log_user_tag RENAME TO idx_audit_log_identity_tag;

-- TODO (CSS-6701): Do we need to rename these instances as well?
-- - ALTER TABLE IF EXISTS controllers RENAME COLUMN admin_user TO admin_identity_name;

-- We don't need to rename columns in these tables, because they're already
-- dropped in an earlier migration:
-- - user_application_offer_access
Expand Down

0 comments on commit 418a569

Please sign in to comment.