-- Deploy gaia:api_2017_08_30_create_table_api_special_rule to mysql

BEGIN;

-- XXX Add DDLs here.
CREATE TABLE `api_special_rule` (
    `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    `special_id` integer NOT NULL,
    `tag_id` integer NOT NULL
)
;
ALTER TABLE `api_special_rule` ADD CONSTRAINT `special_id_refs_id_57902095` FOREIGN KEY (`special_id`) REFERENCES `api_special` (`id`);
ALTER TABLE `api_special_rule` ADD CONSTRAINT `tag_id_refs_id_5659cca1` FOREIGN KEY (`tag_id`) REFERENCES `api_tag` (`id`);

COMMIT;
