summaryrefslogtreecommitdiff
path: root/docs/SQL/mysql/2014101300.sql
blob: cf3ea13bf566a5e60fe54e44882c6e3ffc8f16df (plain)
1
2
3
4
5
6
7
8
9
10
CREATE TABLE IF NOT EXISTS `syncroton_relations_state` (
    `device_id` varchar(40) NOT NULL,
    `folder_id` varchar(40) NOT NULL,
    `synctime` datetime NOT NULL,
    `data` longblob,
    PRIMARY KEY (`device_id`,`folder_id`,`synctime`),
    KEY `syncroton_relations_state::device_id` (`device_id`),
    CONSTRAINT `syncroton_relations_state::device_id--syncroton_device::id`
        FOREIGN KEY (`device_id`) REFERENCES `syncroton_device` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
) /*!40000 ENGINE=INNODB */ /*!40101 CHARACTER SET utf8 COLLATE utf8_general_ci */;