Created
August 24, 2018 09:40
-
-
Save esokullu/cbcb8379aa49ea0637049d832e52493e to your computer and use it in GitHub Desktop.
This file contains hidden or 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
CREATE TABLE `export-requests` ( | |
`id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, | |
`instance_id` int(11) NOT NULL, | |
`requester_id` int(11) NOT NULL, | |
`request_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | |
`fulfill_time` timestamp NULL DEFAULT NULL, | |
PRIMARY KEY (`id`), | |
KEY `instance_id` (`instance_id`), | |
KEY `requester_id` (`requester_id`), | |
CONSTRAINT `export-requests_ibfk_1` FOREIGN KEY (`instance_id`) REFERENCES `instances` (`id`), | |
CONSTRAINT `export-requests_ibfk_2` FOREIGN KEY (`requester_id`) REFERENCES `users` (`id`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It is better to use snake_case for table name:
export_requests