CREATE TABLE `documents` (
  `ID` int UNSIGNED NOT NULL,
  `Language` char(2) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'bg',
  `PostDate` date DEFAULT NULL,
  `LastUpdate` datetime DEFAULT NULL,
  `PageID` int UNSIGNED NOT NULL,
  `UploadID` bigint UNSIGNED NOT NULL DEFAULT '0',
  `Title` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `FileName` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `Visible` tinyint UNSIGNED NOT NULL DEFAULT '0'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

ALTER TABLE `documents`
  ADD PRIMARY KEY (`ID`,`Language`) USING BTREE,
  ADD KEY `Visible` (`Visible`);

