-- Deploy gaia:group_2020_03_02_create_table_group_relation_tag_v3 to mysql

BEGIN;

-- XXX Add DDLs here.
CREATE TABLE `api_group_tag_v3` (
    `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    `group_id` integer NOT NULL,
    `tag_v3_id` integer NOT NULL,
    `is_online` bool NOT NULL,
    `create_time` datetime(6) NOT NULL,
    `update_time` datetime(6) NOT NULL
);

CREATE INDEX `api_group_tag_v3_dc00373b` ON `api_group_tag_v3` (`group_id`);
CREATE INDEX `api_group_tag_v3_9722465e` ON `api_group_tag_v3` (`tag_v3_id`);

COMMIT;
