DROP TABLE IF EXISTS `media_data`;
CREATE TABLE `media_data` (
                              `id` int NOT NULL AUTO_INCREMENT,
                              `media_id` int NOT NULL,
                              `link` varchar(200) NOT NULL,
                              `image` varchar(255) NOT NULL,
                              `desc` text NOT NULL,
                              `title` varchar(255) NOT NULL,
                              `sub_title` varchar(255) NOT NULL,
                              `type` varchar(11) NOT NULL,
                              `sort` int NOT NULL,
                              `language_id` int NOT NULL,
                              `status` tinyint NOT NULL,
                              UNIQUE KEY `id` (`id`),
                              KEY `fk_media_data_id` (`media_id`),
                              CONSTRAINT `fk_media_data_id` FOREIGN KEY (`media_id`) REFERENCES `media` (`id`) ON DELETE CASCADE
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb3;