-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Schema: limit text columns used in keys
Otherwise it's impossible to create an equivalent schema in MySQL. MySQL requires its keys to have a length.
- Loading branch information
Showing
4 changed files
with
33 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ALTER TABLE available_channel_type ALTER COLUMN type TYPE varchar(255); | ||
ALTER TABLE channel ALTER COLUMN type TYPE varchar(255); | ||
ALTER TABLE contact ADD CONSTRAINT ck_contact_username_up_to_254_chars CHECK (length(username) <= 254); | ||
ALTER TABLE contact_address ALTER COLUMN type TYPE varchar(255); | ||
ALTER TABLE object_id_tag ALTER COLUMN tag TYPE varchar(255); | ||
ALTER TABLE object_extra_tag ALTER COLUMN tag TYPE varchar(255); | ||
ALTER TABLE browser_session ADD CONSTRAINT ck_browser_session_username_up_to_254_chars CHECK (length(username) <= 254); |