mirror of
https://github.com/standardebooks/web.git
synced 2025-07-15 02:46:46 -04:00
Add primary keys to multiple tables
I missed these keys when creating the initial schema, and it's a useful practice.
This commit is contained in:
parent
032032b920
commit
79daa82bf4
5 changed files with 10 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
|||
CREATE TABLE `Contributors` (
|
||||
`ContributorId` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`EbookId` int(10) unsigned NOT NULL,
|
||||
`Name` varchar(255) NOT NULL,
|
||||
`UrlName` varchar(255) NOT NULL,
|
||||
|
@ -8,6 +9,7 @@ CREATE TABLE `Contributors` (
|
|||
`FullName` varchar(255) NULL,
|
||||
`NacoafUrl` varchar(255) NULL,
|
||||
`SortOrder` tinyint(3) unsigned NOT NULL,
|
||||
PRIMARY KEY (`ContributorId`),
|
||||
KEY `index1` (`EbookId`),
|
||||
KEY `index2` (`UrlName`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue