Changeset 318
- Timestamp:
- Aug 1, 2011, 7:44:07 PM (13 years ago)
- Location:
- trunk/sql
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sql/full.sql
r265 r318 1 1 -- phpMyAdmin SQL Dump 2 -- version 3. 2.32 -- version 3.4.3.1 3 3 -- http://www.phpmyadmin.net 4 4 -- 5 5 -- Počítač: localhost 6 -- Vygenerováno: Středa 09. prosince 2009, 07:527 -- Verze MySQL: 5. 0.848 -- Verze PHP: 5. 2.96 -- Vygenerováno: Pon 01. srp 2011, 19:43 7 -- Verze MySQL: 5.1.56 8 -- Verze PHP: 5.3.6 9 9 10 10 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; 11 12 -- 13 -- Databáze: `centrala` 14 -- 11 SET time_zone = "+00:00"; 12 13 -- 14 -- Databáze: `is` 15 -- 16 17 DELIMITER $$ 18 -- 19 -- Funkce 20 -- 21 CREATE DEFINER=`centrala`@`localhost` FUNCTION `CompareNetworkPrefix`(Address1 INT(11) UNSIGNED, Address2 INT(11) UNSIGNED, Size INT(11)) RETURNS tinyint(1) 22 RETURN Address1 & (-1 << (32 - Size)) = Address2 & (-1 << (32 - Size))$$ 23 24 DELIMITER ; 15 25 16 26 -- -------------------------------------------------------- … … 21 31 22 32 CREATE TABLE IF NOT EXISTS `ChatHistory` ( 23 `Id` int(11) NOT NULL auto_increment,24 `Nick` varchar(64) collateutf8_czech_ci NOT NULL,25 `Text` text collateutf8_czech_ci NOT NULL,26 `Time` datetime NOT NULL default'0000-00-00 00:00:00',27 `Color` int(11) NOT NULL default'0',28 `RoomName` varchar(32) collateutf8_czech_ci NOT NULL,29 `RoomType` int(11) NOT NULL default'0',30 `Host` varchar(255) collateutf8_czech_ci NOT NULL,31 PRIMARY KEY 32 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=528576 ;33 `Id` int(11) NOT NULL AUTO_INCREMENT, 34 `Nick` varchar(64) COLLATE utf8_czech_ci NOT NULL, 35 `Text` text COLLATE utf8_czech_ci NOT NULL, 36 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 37 `Color` int(11) NOT NULL DEFAULT '0', 38 `RoomName` varchar(32) COLLATE utf8_czech_ci NOT NULL, 39 `RoomType` int(11) NOT NULL DEFAULT '0', 40 `Host` varchar(255) COLLATE utf8_czech_ci NOT NULL, 41 PRIMARY KEY (`Id`) 42 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=528576 ; 33 43 34 44 -- -------------------------------------------------------- … … 39 49 40 50 CREATE TABLE IF NOT EXISTS `DocumentLine` ( 41 `Id` int(11) NOT NULL auto_increment, 42 `Name` varchar(255) collate utf8_czech_ci NOT NULL, 43 `Shortcut` varchar(16) collate utf8_czech_ci NOT NULL, 51 `Id` int(11) NOT NULL AUTO_INCREMENT, 52 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 53 `Shortcut` varchar(16) COLLATE utf8_czech_ci NOT NULL, 54 PRIMARY KEY (`Id`), 55 UNIQUE KEY `Shortcut` (`Shortcut`) 56 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=7 ; 57 58 -- -------------------------------------------------------- 59 60 -- 61 -- Struktura tabulky `DocumentLineSequence` 62 -- 63 64 CREATE TABLE IF NOT EXISTS `DocumentLineSequence` ( 65 `Id` int(11) NOT NULL AUTO_INCREMENT, 66 `DocumentLine` int(11) NOT NULL, 67 `FinanceYear` int(11) NOT NULL, 44 68 `NextNumber` int(11) NOT NULL, 45 PRIMARY KEY (`Id`), 46 UNIQUE KEY `Shortcut` (`Shortcut`) 47 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=7 ; 69 `YearPrefix` int(11) NOT NULL, 70 PRIMARY KEY (`Id`), 71 KEY `DocumentLine` (`DocumentLine`), 72 KEY `FinanceYear` (`FinanceYear`) 73 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=19 ; 48 74 49 75 -- -------------------------------------------------------- … … 54 80 55 81 CREATE TABLE IF NOT EXISTS `EmailQueue` ( 56 `Id` int(11) NOT NULL auto_increment,82 `Id` int(11) NOT NULL AUTO_INCREMENT, 57 83 `Time` datetime NOT NULL, 58 `Address` varchar(255) collate utf8_czech_ci NOT NULL, 59 `Subject` varchar(255) collate utf8_czech_ci NOT NULL, 60 `Content` text collate utf8_czech_ci NOT NULL, 61 `Headers` varchar(255) collate utf8_czech_ci NOT NULL, 62 `Archive` int(11) NOT NULL default '0', 63 PRIMARY KEY (`Id`) 64 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=41 ; 84 `Address` varchar(255) COLLATE utf8_czech_ci NOT NULL, 85 `Subject` varchar(255) COLLATE utf8_czech_ci NOT NULL, 86 `Content` text COLLATE utf8_czech_ci NOT NULL, 87 `Headers` varchar(255) COLLATE utf8_czech_ci NOT NULL, 88 `Archive` int(11) NOT NULL DEFAULT '0', 89 PRIMARY KEY (`Id`), 90 KEY `Archive` (`Archive`) 91 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1631 ; 65 92 66 93 -- -------------------------------------------------------- … … 71 98 72 99 CREATE TABLE IF NOT EXISTS `File` ( 73 `Id` int(11) NOT NULL auto_increment,74 `Name` varchar(256) collateutf8_czech_ci NOT NULL,100 `Id` int(11) NOT NULL AUTO_INCREMENT, 101 `Name` varchar(256) COLLATE utf8_czech_ci NOT NULL, 75 102 `Size` int(11) NOT NULL, 76 PRIMARY KEY 77 ) ENGINE= MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=3;103 PRIMARY KEY (`Id`) 104 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 78 105 79 106 -- -------------------------------------------------------- … … 84 111 85 112 CREATE TABLE IF NOT EXISTS `FinanceAssetsHistory` ( 86 `AssetsId` int(11) NOT NULL default'0',87 `Time` datetime NOT NULL default'0000-00-00 00:00:00',88 `Text` varchar(255) collate utf8_czech_ci NOT NULL default'',89 `User` int(11) NOT NULL default'0',113 `AssetsId` int(11) NOT NULL DEFAULT '0', 114 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 115 `Text` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 116 `User` int(11) NOT NULL DEFAULT '0', 90 117 KEY `AssetsId` (`AssetsId`) 91 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 118 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 119 120 -- -------------------------------------------------------- 121 122 -- 123 -- Struktura tabulky `FinanceBankAccount` 124 -- 125 126 CREATE TABLE IF NOT EXISTS `FinanceBankAccount` ( 127 `Id` int(11) NOT NULL AUTO_INCREMENT, 128 `TimeCreate` date NOT NULL, 129 `Number` varchar(255) COLLATE utf8_czech_ci NOT NULL, 130 `Comment` varchar(255) COLLATE utf8_czech_ci NOT NULL, 131 PRIMARY KEY (`Id`) 132 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=2 ; 92 133 93 134 -- -------------------------------------------------------- … … 98 139 99 140 CREATE TABLE IF NOT EXISTS `FinanceBillingPeriod` ( 100 `Id` int(11) NOT NULL auto_increment,101 `Name` varchar(255) collateutf8_czech_ci NOT NULL,141 `Id` int(11) NOT NULL AUTO_INCREMENT, 142 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 102 143 `MonthCount` int(11) NOT NULL, 103 PRIMARY KEY 104 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6 ;144 PRIMARY KEY (`Id`) 145 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6 ; 105 146 106 147 -- -------------------------------------------------------- … … 111 152 112 153 CREATE TABLE IF NOT EXISTS `FinanceBills` ( 113 `Id` int(11) NOT NULL auto_increment, 114 `TimeFrom` datetime NOT NULL default '0000-00-00 00:00:00', 115 `Subject` int(11) NOT NULL default '0', 116 `TimeTo` datetime NOT NULL default '0000-00-00 00:00:00', 117 `TimeCreate` datetime NOT NULL default '0000-00-00 00:00:00', 118 `TimeDue` datetime NOT NULL default '0000-00-00 00:00:00', 119 `BillCode` varchar(32) collate utf8_czech_ci NOT NULL, 120 `Type` enum('invoice','income') collate utf8_czech_ci NOT NULL, 121 `Cash` int(11) NOT NULL default '0', 122 PRIMARY KEY (`Id`) 123 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1941 ; 154 `Id` int(11) NOT NULL AUTO_INCREMENT, 155 `TimeFrom` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 156 `Subject` int(11) NOT NULL DEFAULT '0', 157 `TimeTo` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 158 `TimeCreate` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 159 `TimeDue` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 160 `BillCode` varchar(32) COLLATE utf8_czech_ci NOT NULL, 161 `Type` enum('invoice','income') COLLATE utf8_czech_ci NOT NULL, 162 `Cash` int(11) NOT NULL DEFAULT '0', 163 PRIMARY KEY (`Id`), 164 KEY `Subject` (`Subject`), 165 KEY `Subject_2` (`Subject`) 166 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4362 ; 124 167 125 168 -- -------------------------------------------------------- … … 130 173 131 174 CREATE TABLE IF NOT EXISTS `FinanceBillsItems` ( 132 `Id` int(11) NOT NULL auto_increment, 133 `Bill` int(11) NOT NULL default '0', 134 `Description` varchar(255) collate utf8_czech_ci NOT NULL, 135 `Price` float NOT NULL default '0', 136 `Quantity` float NOT NULL default '1', 137 PRIMARY KEY (`Id`) 138 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=13482 ; 175 `Id` int(11) NOT NULL AUTO_INCREMENT, 176 `Bill` int(11) NOT NULL DEFAULT '0', 177 `Description` varchar(255) COLLATE utf8_czech_ci NOT NULL, 178 `Price` float NOT NULL DEFAULT '0', 179 `Quantity` float NOT NULL DEFAULT '1', 180 PRIMARY KEY (`Id`), 181 KEY `Bill` (`Bill`) 182 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=15903 ; 139 183 140 184 -- -------------------------------------------------------- … … 145 189 146 190 CREATE TABLE IF NOT EXISTS `FinanceClaimsLiabilities` ( 147 `Id` int(11) NOT NULL auto_increment, 148 `BillCode` varchar(16) collate utf8_czech_ci NOT NULL, 149 `Subject` int(11) NOT NULL default '0', 150 `TimeCreation` datetime NOT NULL default '0000-00-00 00:00:00', 151 `TimeDue` datetime NOT NULL default '0000-00-00 00:00:00', 152 `TimePayment` datetime NOT NULL default '0000-00-00 00:00:00', 153 `Value` float NOT NULL default '0', 154 `Bill` int(11) NOT NULL default '0', 155 `Text` varchar(255) collate utf8_czech_ci NOT NULL default '', 156 PRIMARY KEY (`Id`) 157 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4455 ; 191 `Id` int(11) NOT NULL AUTO_INCREMENT, 192 `BillCode` varchar(16) COLLATE utf8_czech_ci NOT NULL, 193 `Subject` int(11) NOT NULL DEFAULT '0', 194 `TimeCreation` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 195 `TimeDue` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 196 `TimePayment` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 197 `Value` float NOT NULL DEFAULT '0', 198 `Bill` int(11) DEFAULT '0', 199 `Text` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 200 PRIMARY KEY (`Id`), 201 KEY `Subject` (`Subject`), 202 KEY `Bill` (`Bill`) 203 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6805 ; 158 204 159 205 -- -------------------------------------------------------- … … 164 210 165 211 CREATE TABLE IF NOT EXISTS `FinanceLog` ( 166 `Id` int(11) NOT NULL auto_increment,167 `Time` datetime NOT NULL default'0000-00-00 00:00:00',168 `Text` varchar(255) collate utf8_czech_ci NOT NULL default'',169 PRIMARY KEY 170 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ;212 `Id` int(11) NOT NULL AUTO_INCREMENT, 213 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 214 `Text` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 215 PRIMARY KEY (`Id`) 216 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 171 217 172 218 -- -------------------------------------------------------- … … 177 223 178 224 CREATE TABLE IF NOT EXISTS `FinanceOperation` ( 179 `Id` int(11) NOT NULL auto_increment,225 `Id` int(11) NOT NULL AUTO_INCREMENT, 180 226 `Time` datetime NOT NULL, 181 `Subject` int(11) NOT NULL default'0',182 `Cash` int(11) NOT NULL default'0',227 `Subject` int(11) NOT NULL DEFAULT '0', 228 `Cash` int(11) NOT NULL DEFAULT '0', 183 229 `Value` float NOT NULL, 184 `BillCode` varchar(32) collate utf8_czech_ci NOT NULL, 185 `Taxable` tinyint(1) NOT NULL default '1', 186 `Bill` int(11) NOT NULL, 187 `Text` varchar(255) collate utf8_czech_ci NOT NULL default 'Vklad', 188 `Network` int(11) NOT NULL default '1', 189 PRIMARY KEY (`Id`) 190 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4311 ; 230 `BillCode` varchar(32) COLLATE utf8_czech_ci NOT NULL, 231 `Taxable` tinyint(1) NOT NULL DEFAULT '1', 232 `Bill` int(11) DEFAULT NULL, 233 `Text` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT 'Vklad', 234 `Network` int(11) NOT NULL DEFAULT '1', 235 PRIMARY KEY (`Id`), 236 KEY `Subject` (`Subject`), 237 KEY `Bill` (`Bill`) 238 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=5459 ; 191 239 192 240 -- -------------------------------------------------------- … … 197 245 198 246 CREATE TABLE IF NOT EXISTS `FinanceSmallAssets` ( 199 `Id` int(11) NOT NULL auto_increment,200 `Text` varchar(255) collate utf8_czech_ci NOT NULL default'',201 `PricePurchase` float NOT NULL default'0',202 `TimeEnlistment` datetime NOT NULL default'0000-00-00 00:00:00',203 `TimeElimination` datetime NOT NULL default'0000-00-00 00:00:00',204 `SupplySubject` int(11) NOT NULL default'0',205 `DeviceId` varchar(128) collate utf8_czech_ci NOT NULL default'',206 PRIMARY KEY 207 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ;247 `Id` int(11) NOT NULL AUTO_INCREMENT, 248 `Text` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 249 `PricePurchase` float NOT NULL DEFAULT '0', 250 `TimeEnlistment` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 251 `TimeElimination` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 252 `SupplySubject` int(11) NOT NULL DEFAULT '0', 253 `DeviceId` varchar(128) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 254 PRIMARY KEY (`Id`) 255 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 208 256 209 257 -- -------------------------------------------------------- … … 214 262 215 263 CREATE TABLE IF NOT EXISTS `FinanceTariff` ( 216 `Id` int(11) NOT NULL auto_increment, 217 `Tariff` int(11) NOT NULL default '0', 218 `Period` int(11) NOT NULL default '0', 219 `Name` varchar(32) collate utf8_czech_ci NOT NULL, 220 `Group` int(11) NOT NULL default '0', 221 `SpeedMin` int(11) NOT NULL default '0', 222 `SpeedMax` int(11) NOT NULL default '0', 223 `UploadAsymmetry` int(11) NOT NULL default '1', 224 `Price` int(11) NOT NULL default '0', 225 `MemberCount` int(11) NOT NULL default '0', 226 PRIMARY KEY (`Id`) 227 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=33 ; 264 `Id` int(11) NOT NULL AUTO_INCREMENT, 265 `Tariff` int(11) NOT NULL DEFAULT '0', 266 `Period` int(11) NOT NULL DEFAULT '0', 267 `Name` varchar(32) COLLATE utf8_czech_ci NOT NULL, 268 `Group` int(11) NOT NULL DEFAULT '0', 269 `SpeedMin` int(11) NOT NULL DEFAULT '0', 270 `SpeedMax` int(11) NOT NULL DEFAULT '0', 271 `UploadAsymmetry` int(11) NOT NULL DEFAULT '1', 272 `Price` int(11) NOT NULL DEFAULT '0', 273 `MemberCount` int(11) NOT NULL DEFAULT '0', 274 PRIMARY KEY (`Id`), 275 KEY `Tariff` (`Tariff`) 276 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=288 ; 277 278 -- -------------------------------------------------------- 279 280 -- 281 -- Struktura tabulky `FinanceYear` 282 -- 283 284 CREATE TABLE IF NOT EXISTS `FinanceYear` ( 285 `Id` int(11) NOT NULL AUTO_INCREMENT, 286 `Year` int(11) NOT NULL, 287 `DateStart` date NOT NULL, 288 `DateEnd` date NOT NULL, 289 PRIMARY KEY (`Id`) 290 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=7 ; 228 291 229 292 -- -------------------------------------------------------- … … 234 297 235 298 CREATE TABLE IF NOT EXISTS `finance_charge` ( 236 `period` int(11) NOT NULL default'0',237 `internet` int(11) NOT NULL default'0',238 `internet_speed` int(11) NOT NULL default'0',239 `internet_speed_reserve` int(11) NOT NULL default'0',240 `administration_per_user` int(20) NOT NULL default'0',241 `kWh` int(11) NOT NULL default'0',242 `base_speed_element` int(11) NOT NULL default'0',243 `BaseTariffPrice` int(11) NOT NULL default'0',244 `TopTariffPrice` int(11) NOT NULL default'0'245 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci;299 `period` int(11) NOT NULL DEFAULT '0', 300 `internet` int(11) NOT NULL DEFAULT '0', 301 `internet_speed` int(11) NOT NULL DEFAULT '0', 302 `internet_speed_reserve` int(11) NOT NULL DEFAULT '0', 303 `administration_per_user` int(20) NOT NULL DEFAULT '0', 304 `kWh` int(11) NOT NULL DEFAULT '0', 305 `base_speed_element` int(11) NOT NULL DEFAULT '0', 306 `BaseTariffPrice` int(11) NOT NULL DEFAULT '0', 307 `TopTariffPrice` int(11) NOT NULL DEFAULT '0' 308 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 246 309 247 310 -- -------------------------------------------------------- … … 252 315 253 316 CREATE TABLE IF NOT EXISTS `finance_groups` ( 254 `Id` int(11) NOT NULL auto_increment,255 `Description` varchar(128) collate utf8_czech_ci NOT NULL default'',256 PRIMARY KEY 257 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4 ;317 `Id` int(11) NOT NULL AUTO_INCREMENT, 318 `Description` varchar(128) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 319 PRIMARY KEY (`Id`) 320 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4 ; 258 321 259 322 -- -------------------------------------------------------- … … 264 327 265 328 CREATE TABLE IF NOT EXISTS `finance_monthly_overall` ( 266 `id` int(11) NOT NULL auto_increment,267 `money` int(11) NOT NULL default'0',268 `date` date NOT NULL default'0000-00-00',269 `administration` int(11) NOT NULL default'0',270 `kWh` int(11) NOT NULL default'0',271 `administration_total` int(11) NOT NULL default'0',272 `consumption_total` int(11) NOT NULL default'0',273 `total_paid` int(11) NOT NULL default'0',274 `BaseTariffPrice` int(11) NOT NULL default'0',275 `TopTariffPrice` int(11) NOT NULL default'0',276 `member_count` int(11) NOT NULL default'0',329 `id` int(11) NOT NULL AUTO_INCREMENT, 330 `money` int(11) NOT NULL DEFAULT '0', 331 `date` date NOT NULL DEFAULT '0000-00-00', 332 `administration` int(11) NOT NULL DEFAULT '0', 333 `kWh` int(11) NOT NULL DEFAULT '0', 334 `administration_total` int(11) NOT NULL DEFAULT '0', 335 `consumption_total` int(11) NOT NULL DEFAULT '0', 336 `total_paid` int(11) NOT NULL DEFAULT '0', 337 `BaseTariffPrice` int(11) NOT NULL DEFAULT '0', 338 `TopTariffPrice` int(11) NOT NULL DEFAULT '0', 339 `member_count` int(11) NOT NULL DEFAULT '0', 277 340 `investment` int(11) NOT NULL, 278 PRIMARY KEY (`id`) 279 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=78 ; 280 281 -- -------------------------------------------------------- 282 283 -- 284 -- Struktura tabulky `History` 285 -- 286 287 CREATE TABLE IF NOT EXISTS `History` ( 288 `Id` int(11) NOT NULL auto_increment, 289 `Date` date NOT NULL, 290 `Text` text collate utf8_czech_ci NOT NULL, 291 PRIMARY KEY (`Id`) 292 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=21 ; 341 PRIMARY KEY (`id`) 342 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=103 ; 293 343 294 344 -- -------------------------------------------------------- … … 299 349 300 350 CREATE TABLE IF NOT EXISTS `HostedProject` ( 301 `Id` int(11) NOT NULL auto_increment,302 `Name` varchar(255) collateutf8_czech_ci NOT NULL,303 `Homepage` varchar(255) collateutf8_czech_ci NOT NULL,351 `Id` int(11) NOT NULL AUTO_INCREMENT, 352 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 353 `Homepage` varchar(255) COLLATE utf8_czech_ci NOT NULL, 304 354 `User` int(255) NOT NULL COMMENT 'User.Id', 305 355 `TimeCreate` datetime NOT NULL, 306 `Server` int(11) default NULL COMMENT 'NetworkDevice.Id', 307 PRIMARY KEY (`Id`) 308 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6 ; 356 `Server` int(11) DEFAULT NULL COMMENT 'NetworkDevice.Id', 357 `Active` int(11) NOT NULL DEFAULT '1', 358 `WebHosting` int(11) NOT NULL, 359 PRIMARY KEY (`Id`) 360 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=16 ; 309 361 310 362 -- -------------------------------------------------------- … … 315 367 316 368 CREATE TABLE IF NOT EXISTS `hosts_topology` ( 317 `host` int(11) NOT NULL default'0',318 `depth` int(11) NOT NULL default'0',319 `pos` int(11) NOT NULL default'0',320 `first` int(11) NOT NULL default'0',321 `last` int(11) NOT NULL default'0',322 PRIMARY KEY 323 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci;369 `host` int(11) NOT NULL DEFAULT '0', 370 `depth` int(11) NOT NULL DEFAULT '0', 371 `pos` int(11) NOT NULL DEFAULT '0', 372 `first` int(11) NOT NULL DEFAULT '0', 373 `last` int(11) NOT NULL DEFAULT '0', 374 PRIMARY KEY (`host`) 375 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 324 376 325 377 -- -------------------------------------------------------- … … 330 382 331 383 CREATE TABLE IF NOT EXISTS `Hyperlink` ( 332 `Id` int(11) NOT NULL auto_increment,333 `Name` varchar(255) collateutf8_czech_ci NOT NULL,334 `URL` varchar(255) collateutf8_czech_ci NOT NULL,384 `Id` int(11) NOT NULL AUTO_INCREMENT, 385 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 386 `URL` varchar(255) COLLATE utf8_czech_ci NOT NULL, 335 387 `Group` int(11) NOT NULL, 336 `IconFile` varchar(255) collateutf8_czech_ci NOT NULL,337 `PermissionModule` varchar(255) collateutf8_czech_ci NOT NULL,338 `PermissionOperation` varchar(255) collateutf8_czech_ci NOT NULL,339 `Enable` int(11) NOT NULL default'1',340 PRIMARY KEY 388 `IconFile` varchar(255) COLLATE utf8_czech_ci NOT NULL, 389 `PermissionModule` varchar(255) COLLATE utf8_czech_ci NOT NULL, 390 `PermissionOperation` varchar(255) COLLATE utf8_czech_ci NOT NULL, 391 `Enable` int(11) NOT NULL DEFAULT '1', 392 PRIMARY KEY (`Id`), 341 393 KEY `Group` (`Group`), 342 394 KEY `Enable` (`Enable`) 343 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT= 57;395 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=66 ; 344 396 345 397 -- -------------------------------------------------------- … … 350 402 351 403 CREATE TABLE IF NOT EXISTS `HyperlinkGroup` ( 352 `Id` int(11) NOT NULL auto_increment,353 `Name` varchar(255) collateutf8_czech_ci NOT NULL,354 PRIMARY KEY 355 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT= 9;404 `Id` int(11) NOT NULL AUTO_INCREMENT, 405 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 406 PRIMARY KEY (`Id`) 407 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=10 ; 356 408 357 409 -- -------------------------------------------------------- … … 362 414 363 415 CREATE TABLE IF NOT EXISTS `Log` ( 364 `Time` datetime NOT NULL default '0000-00-00 00:00:00', 365 `User` int(11) NOT NULL default '0', 366 `Module` varchar(64) collate utf8_czech_ci NOT NULL default '', 367 `Operation` varchar(255) collate utf8_czech_ci NOT NULL default '', 368 `Value` varchar(255) collate utf8_czech_ci NOT NULL default '', 369 KEY `Time` (`Time`) 370 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 416 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 417 `User` int(11) NOT NULL DEFAULT '0', 418 `Module` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 419 `Operation` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 420 `Value` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 421 KEY `Time` (`Time`), 422 KEY `User` (`User`) 423 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 371 424 372 425 -- -------------------------------------------------------- … … 377 430 378 431 CREATE TABLE IF NOT EXISTS `Meals` ( 379 `Date` date NOT NULL default'0000-00-00',380 `Soup` varchar(255) collateutf8_czech_ci NOT NULL,381 `Meal` varchar(255) collateutf8_czech_ci NOT NULL,382 `Status` int(11) NOT NULL default'0',432 `Date` date NOT NULL DEFAULT '0000-00-00', 433 `Soup` varchar(255) COLLATE utf8_czech_ci NOT NULL, 434 `Meal` varchar(255) COLLATE utf8_czech_ci NOT NULL, 435 `Status` int(11) NOT NULL DEFAULT '0', 383 436 UNIQUE KEY `date` (`Date`) 384 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci ROW_FORMAT=DYNAMIC;437 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci ROW_FORMAT=DYNAMIC; 385 438 386 439 -- -------------------------------------------------------- … … 391 444 392 445 CREATE TABLE IF NOT EXISTS `MealsInfo` ( 393 `Info` text collateutf8_czech_ci NOT NULL,394 `Price` int(11) NOT NULL default'0'395 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci ROW_FORMAT=DYNAMIC;446 `Info` text COLLATE utf8_czech_ci NOT NULL, 447 `Price` int(11) NOT NULL DEFAULT '0' 448 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci ROW_FORMAT=DYNAMIC; 396 449 397 450 -- -------------------------------------------------------- … … 402 455 403 456 CREATE TABLE IF NOT EXISTS `Member` ( 404 `Id` int(11) NOT NULL auto_increment, 457 `Id` int(11) NOT NULL AUTO_INCREMENT, 458 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 405 459 `Subject` int(11) NOT NULL, 406 460 `ResponsibleUser` int(11) NOT NULL, … … 411 465 `InternetTariffNextMonth` int(11) NOT NULL, 412 466 `GPS` int(11) NOT NULL, 413 `BillingPeriod` int(11) NOT NULL default'2',467 `BillingPeriod` int(11) NOT NULL DEFAULT '2', 414 468 `NetworkSegment` int(11) NOT NULL, 415 `BillingPeriodNext` int(11) NOT NULL default'2',469 `BillingPeriodNext` int(11) NOT NULL DEFAULT '2', 416 470 `BillingPeriodLastDate` date NOT NULL, 417 `Hire` float NOT NULL default '0', 418 PRIMARY KEY (`Id`) 419 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=103 ; 471 `Hire` float NOT NULL DEFAULT '0', 472 `Blocked` int(11) NOT NULL DEFAULT '0', 473 PRIMARY KEY (`Id`), 474 KEY `Subject` (`Subject`), 475 KEY `ResponsibleUser` (`ResponsibleUser`), 476 KEY `InternetTariffCurrentMonth` (`InternetTariffCurrentMonth`), 477 KEY `InternetTariffNextMonth` (`InternetTariffNextMonth`), 478 KEY `BillingPeriod` (`BillingPeriod`), 479 KEY `BillingPeriodNext` (`BillingPeriodNext`) 480 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=162 ; 420 481 421 482 -- -------------------------------------------------------- … … 426 487 427 488 CREATE TABLE IF NOT EXISTS `MemberPayment` ( 428 `Id` int(11) NOT NULL auto_increment,489 `Id` int(11) NOT NULL AUTO_INCREMENT, 429 490 `Member` int(11) NOT NULL, 430 491 `MonthlyTotal` float NOT NULL, … … 434 495 `MonthlyPlus` float NOT NULL, 435 496 `Cash` float NOT NULL, 436 PRIMARY KEY (`Id`) 437 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=87 ; 497 PRIMARY KEY (`Id`), 498 KEY `Member` (`Member`) 499 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=145 ; 438 500 439 501 -- -------------------------------------------------------- … … 444 506 445 507 CREATE TABLE IF NOT EXISTS `NetworkAP` ( 446 `Id` int(11) NOT NULL auto_increment,447 `SSID` varchar(255) collateutf8_czech_ci NOT NULL,508 `Id` int(11) NOT NULL AUTO_INCREMENT, 509 `SSID` varchar(255) COLLATE utf8_czech_ci NOT NULL, 448 510 `Frequency` int(11) NOT NULL, 449 `ChannelWidth` int(11) NOT NULL default '20', 450 `NetworkDevice` int(11) default NULL, 451 PRIMARY KEY (`Id`) 452 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=31 ; 511 `ChannelWidth` int(11) NOT NULL DEFAULT '20', 512 `NetworkDevice` int(11) DEFAULT NULL, 513 PRIMARY KEY (`Id`), 514 KEY `NetworkDevice` (`NetworkDevice`) 515 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=43 ; 453 516 454 517 -- -------------------------------------------------------- … … 459 522 460 523 CREATE TABLE IF NOT EXISTS `NetworkConfiguration` ( 461 `Id` int(11) NOT NULL auto_increment,462 `Caption` varchar(255) collateutf8_czech_ci NOT NULL,463 `Execute` varchar(255) collateutf8_czech_ci NOT NULL,464 `Changed` int(11) NOT NULL default'0',465 `LastTime` datetime NOT NULL default'0000-00-00 00:00:00',524 `Id` int(11) NOT NULL AUTO_INCREMENT, 525 `Caption` varchar(255) COLLATE utf8_czech_ci NOT NULL, 526 `Execute` varchar(255) COLLATE utf8_czech_ci NOT NULL, 527 `Changed` int(11) NOT NULL DEFAULT '0', 528 `LastTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 466 529 `ExecutionTime` int(11) NOT NULL, 467 `Enabled` int(11) NOT NULL default'1',468 `Period` int(11) NOT NULL default'60',469 `Log` mediumtext collateutf8_czech_ci NOT NULL,470 PRIMARY KEY 471 ) ENGINE= MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=11;530 `Enabled` int(11) NOT NULL DEFAULT '1', 531 `Period` int(11) NOT NULL DEFAULT '60', 532 `Log` mediumtext COLLATE utf8_czech_ci NOT NULL, 533 PRIMARY KEY (`Id`) 534 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=14 ; 472 535 473 536 -- -------------------------------------------------------- … … 478 541 479 542 CREATE TABLE IF NOT EXISTS `NetworkDevice` ( 480 `Id` int(11) NOT NULL auto_increment, 481 `Name` varchar(255) collate utf8_czech_ci NOT NULL, 482 `Member` int(11) NOT NULL, 543 `Id` int(11) NOT NULL AUTO_INCREMENT, 544 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 545 `Member` int(11) NOT NULL COMMENT 'Member', 546 `Location` int(11) NOT NULL COMMENT 'Member', 547 `Type` int(11) NOT NULL COMMENT 'NetworkDeviceType', 548 `PositionLatitude` double NOT NULL DEFAULT '0', 549 `PositionLongitude` double NOT NULL DEFAULT '0', 550 `Used` int(11) NOT NULL DEFAULT '1', 551 `Online` int(11) NOT NULL DEFAULT '0', 552 `LastOnline` datetime NOT NULL, 553 `PermanentOnline` int(11) NOT NULL, 554 `InboundNATPriority` int(11) NOT NULL DEFAULT '1', 555 PRIMARY KEY (`Id`), 556 UNIQUE KEY `Name` (`Name`), 557 KEY `Member` (`Member`), 558 KEY `Location` (`Location`), 559 KEY `Type` (`Type`) 560 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=590 ; 561 562 -- -------------------------------------------------------- 563 564 -- 565 -- Struktura tabulky `NetworkDeviceHistory` 566 -- 567 568 CREATE TABLE IF NOT EXISTS `NetworkDeviceHistory` ( 569 `Id` int(11) NOT NULL AUTO_INCREMENT, 570 `Device` int(11) NOT NULL DEFAULT '0', 571 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 572 `Action` int(11) NOT NULL DEFAULT '0', 573 `Notice` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 574 PRIMARY KEY (`Id`), 575 KEY `Device` (`Device`) 576 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 577 578 -- -------------------------------------------------------- 579 580 -- 581 -- Struktura tabulky `NetworkDeviceType` 582 -- 583 584 CREATE TABLE IF NOT EXISTS `NetworkDeviceType` ( 585 `Id` int(11) NOT NULL AUTO_INCREMENT, 586 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 587 `ShowOnline` int(11) NOT NULL DEFAULT '0', 588 `IconName` varchar(255) COLLATE utf8_czech_ci NOT NULL, 589 PRIMARY KEY (`Id`) 590 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=10 ; 591 592 -- -------------------------------------------------------- 593 594 -- 595 -- Struktura tabulky `NetworkDomainAlias` 596 -- 597 598 CREATE TABLE IF NOT EXISTS `NetworkDomainAlias` ( 599 `Id` int(11) NOT NULL AUTO_INCREMENT, 600 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 601 `Target` varchar(255) COLLATE utf8_czech_ci NOT NULL, 602 `Comment` varchar(255) COLLATE utf8_czech_ci NOT NULL, 603 PRIMARY KEY (`Id`) 604 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=32 ; 605 606 -- -------------------------------------------------------- 607 608 -- 609 -- Struktura tabulky `NetworkFirewall` 610 -- 611 612 CREATE TABLE IF NOT EXISTS `NetworkFirewall` ( 613 `Id` int(11) NOT NULL AUTO_INCREMENT, 614 `NetworkDevice` int(11) NOT NULL, 615 `SourceInterface` varchar(255) COLLATE utf8_czech_ci DEFAULT NULL, 616 `DestinationInterface` varchar(255) COLLATE utf8_czech_ci DEFAULT NULL, 617 `SourceAddress` varchar(255) COLLATE utf8_czech_ci DEFAULT NULL, 618 `DestinationAddress` varchar(255) COLLATE utf8_czech_ci DEFAULT NULL, 619 `SourcePort` int(11) DEFAULT NULL, 620 `DestinationPort` int(11) DEFAULT NULL, 621 `Action` varchar(255) COLLATE utf8_czech_ci NOT NULL, 622 `Comment` varchar(255) COLLATE utf8_czech_ci NOT NULL, 623 PRIMARY KEY (`Id`), 624 KEY `NetworkDevice` (`NetworkDevice`) 625 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=8 ; 626 627 -- -------------------------------------------------------- 628 629 -- 630 -- Struktura tabulky `NetworkInterface` 631 -- 632 633 CREATE TABLE IF NOT EXISTS `NetworkInterface` ( 634 `Id` int(11) NOT NULL AUTO_INCREMENT, 635 `Name` varchar(16) COLLATE utf8_czech_ci NOT NULL, 483 636 `Type` int(11) NOT NULL, 484 `PositionLatitude` double NOT NULL default '0', 485 `PositionLongitude` double NOT NULL default '0', 486 `Used` int(11) NOT NULL default '1', 487 `Online` int(11) NOT NULL default '0', 637 `MAC` varchar(17) COLLATE utf8_czech_ci NOT NULL, 638 `LocalIP` varchar(16) COLLATE utf8_czech_ci NOT NULL, 639 `IPv6` varchar(255) COLLATE utf8_czech_ci NOT NULL, 640 `ExternalIP` varchar(16) COLLATE utf8_czech_ci NOT NULL, 641 `Device` int(11) NOT NULL, 642 `Online` int(11) NOT NULL DEFAULT '0', 488 643 `LastOnline` datetime NOT NULL, 489 PRIMARY KEY (`Id`), 490 KEY `Member` (`Member`) 491 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=413 ; 492 493 -- -------------------------------------------------------- 494 495 -- 496 -- Struktura tabulky `NetworkDeviceHistory` 497 -- 498 499 CREATE TABLE IF NOT EXISTS `NetworkDeviceHistory` ( 500 `Id` int(11) NOT NULL auto_increment, 501 `Device` int(11) NOT NULL default '0', 502 `Time` datetime NOT NULL default '0000-00-00 00:00:00', 503 `Action` int(11) NOT NULL default '0', 504 `Notice` varchar(255) collate utf8_czech_ci NOT NULL default '', 505 PRIMARY KEY (`Id`) 506 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 507 508 -- -------------------------------------------------------- 509 510 -- 511 -- Struktura tabulky `NetworkDeviceType` 512 -- 513 514 CREATE TABLE IF NOT EXISTS `NetworkDeviceType` ( 515 `Id` int(11) NOT NULL auto_increment, 516 `Name` varchar(255) collate utf8_czech_ci NOT NULL, 517 `ShowOnline` int(11) NOT NULL default '0', 518 `IconName` varchar(255) collate utf8_czech_ci NOT NULL, 519 PRIMARY KEY (`Id`) 520 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=10 ; 521 522 -- -------------------------------------------------------- 523 524 -- 525 -- Struktura tabulky `NetworkDomainAlias` 526 -- 527 528 CREATE TABLE IF NOT EXISTS `NetworkDomainAlias` ( 529 `Id` int(11) NOT NULL auto_increment, 530 `Name` varchar(255) collate utf8_czech_ci NOT NULL, 531 `Target` varchar(255) collate utf8_czech_ci NOT NULL, 532 PRIMARY KEY (`Id`) 533 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=20 ; 534 535 -- -------------------------------------------------------- 536 537 -- 538 -- Struktura tabulky `NetworkInterface` 539 -- 540 541 CREATE TABLE IF NOT EXISTS `NetworkInterface` ( 542 `Id` int(11) NOT NULL auto_increment, 543 `Name` varchar(16) collate utf8_czech_ci NOT NULL, 544 `Type` int(11) NOT NULL, 545 `MAC` varchar(17) collate utf8_czech_ci NOT NULL, 546 `LocalIP` varchar(16) collate utf8_czech_ci NOT NULL, 547 `ExternalIP` varchar(16) collate utf8_czech_ci NOT NULL, 548 `CZFreeIP` varchar(16) collate utf8_czech_ci NOT NULL, 549 `Device` int(11) NOT NULL, 550 `Online` int(11) NOT NULL default '0', 551 `LastOnline` datetime NOT NULL, 552 PRIMARY KEY (`Id`), 553 KEY `Device` (`Device`) 554 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=440 ; 644 PRIMARY KEY (`Id`), 645 KEY `Device` (`Device`), 646 KEY `Type` (`Type`) 647 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=649 ; 648 649 -- -------------------------------------------------------- 650 651 -- 652 -- Struktura tabulky `NetworkInterfacePortable` 653 -- 654 655 CREATE TABLE IF NOT EXISTS `NetworkInterfacePortable` ( 656 `Id` int(11) NOT NULL AUTO_INCREMENT, 657 `NetworkInterface` int(11) NOT NULL, 658 `DynamicIP` varchar(255) COLLATE utf8_czech_ci NOT NULL, 659 `Time` datetime NOT NULL, 660 `Update` int(11) NOT NULL, 661 PRIMARY KEY (`Id`), 662 KEY `NetworkInterface` (`NetworkInterface`), 663 KEY `Update` (`Update`) 664 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 555 665 556 666 -- -------------------------------------------------------- … … 561 671 562 672 CREATE TABLE IF NOT EXISTS `NetworkInterfaceStat` ( 563 `NetworkInterface` int(11) NOT NULL default'0',564 `Time` datetime NOT NULL default'0000-00-00 00:00:00',565 `PingCount` smallint(11) NOT NULL default'0',673 `NetworkInterface` int(11) NOT NULL DEFAULT '0', 674 `Time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 675 `PingCount` smallint(11) NOT NULL DEFAULT '0', 566 676 KEY `host_id` (`NetworkInterface`), 567 677 KEY `time` (`Time`) … … 575 685 576 686 CREATE TABLE IF NOT EXISTS `NetworkInterfaceType` ( 577 `Id` int(11) NOT NULL auto_increment,578 `Name` varchar(255) collateutf8_czech_ci NOT NULL,687 `Id` int(11) NOT NULL AUTO_INCREMENT, 688 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 579 689 `MaxSpeed` int(11) NOT NULL, 580 `FullDuplex` int(11) NOT NULL default'1',581 `Color` varchar(6) collate utf8_czech_ci NOT NULL default'ffffff',582 PRIMARY KEY 583 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=8 ;690 `FullDuplex` int(11) NOT NULL DEFAULT '1', 691 `Color` varchar(6) COLLATE utf8_czech_ci NOT NULL DEFAULT 'ffffff', 692 PRIMARY KEY (`Id`) 693 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=8 ; 584 694 585 695 -- -------------------------------------------------------- … … 590 700 591 701 CREATE TABLE IF NOT EXISTS `NetworkLink` ( 592 `Id` int(11) NOT NULL auto_increment,702 `Id` int(11) NOT NULL AUTO_INCREMENT, 593 703 `Type` int(11) NOT NULL, 594 704 `Interface1` int(11) NOT NULL, 595 705 `Interface2` int(11) NOT NULL, 596 PRIMARY KEY (`Id`) 597 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=356 ; 706 PRIMARY KEY (`Id`), 707 KEY `Interface1` (`Interface1`), 708 KEY `Interface2` (`Interface2`) 709 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=356 ; 710 711 -- -------------------------------------------------------- 712 713 -- 714 -- Struktura tabulky `NetworkMangleSubgroup` 715 -- 716 717 CREATE TABLE IF NOT EXISTS `NetworkMangleSubgroup` ( 718 `Id` int(11) NOT NULL AUTO_INCREMENT, 719 `AddressRange` varchar(255) COLLATE utf8_czech_ci NOT NULL, 720 PRIMARY KEY (`Id`), 721 KEY `AddressRange` (`AddressRange`) 722 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=126 ; 598 723 599 724 -- -------------------------------------------------------- … … 604 729 605 730 CREATE TABLE IF NOT EXISTS `NetworkMark` ( 606 `Id` int(11) NOT NULL auto_increment,607 `Comment` varchar(255) collateutf8_czech_ci NOT NULL,608 PRIMARY KEY 731 `Id` int(11) NOT NULL AUTO_INCREMENT, 732 `Comment` varchar(255) COLLATE utf8_czech_ci NOT NULL, 733 PRIMARY KEY (`Id`), 609 734 KEY `Comment` (`Comment`) 610 ) ENGINE= MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=575;735 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1189 ; 611 736 612 737 -- -------------------------------------------------------- … … 617 742 618 743 CREATE TABLE IF NOT EXISTS `NetworkSubnet` ( 619 `Id` int(11) NOT NULL auto_increment,620 `Name` varchar(255) collateutf8_czech_ci NOT NULL,621 `AddressRange` varchar(255) collateutf8_czech_ci NOT NULL,744 `Id` int(11) NOT NULL AUTO_INCREMENT, 745 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 746 `AddressRange` varchar(255) COLLATE utf8_czech_ci NOT NULL, 622 747 `Mask` int(11) NOT NULL, 623 `DHCP` varchar(255) collate utf8_czech_ci NOT NULL, 624 `Gateway` varchar(255) collate utf8_czech_ci NOT NULL, 625 `WINS` varchar(255) collate utf8_czech_ci NOT NULL, 626 `DNS` varchar(255) collate utf8_czech_ci NOT NULL, 627 `Domain` varchar(255) collate utf8_czech_ci NOT NULL, 628 `NTP` varchar(255) collate utf8_czech_ci NOT NULL, 629 `Member` int(11) NOT NULL default '0', 630 `ExtAddressRange` varchar(255) collate utf8_czech_ci NOT NULL, 631 `ExtMask` int(11) NOT NULL default '32', 632 PRIMARY KEY (`Id`) 633 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=18 ; 748 `DHCP` varchar(255) COLLATE utf8_czech_ci NOT NULL, 749 `Gateway` varchar(255) COLLATE utf8_czech_ci NOT NULL, 750 `WINS` varchar(255) COLLATE utf8_czech_ci NOT NULL, 751 `DNS` varchar(255) COLLATE utf8_czech_ci NOT NULL, 752 `Domain` varchar(255) COLLATE utf8_czech_ci NOT NULL, 753 `NTP` varchar(255) COLLATE utf8_czech_ci NOT NULL, 754 `Member` int(11) DEFAULT NULL, 755 `ExtAddressRange` varchar(255) COLLATE utf8_czech_ci NOT NULL, 756 `ExtMask` int(11) NOT NULL DEFAULT '32', 757 `AddressRangeIPv6` varchar(255) COLLATE utf8_czech_ci NOT NULL, 758 PRIMARY KEY (`Id`), 759 KEY `Member` (`Member`) 760 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=39 ; 634 761 635 762 -- -------------------------------------------------------- … … 640 767 641 768 CREATE TABLE IF NOT EXISTS `network_devices` ( 642 `id` int(11) NOT NULL auto_increment,643 `name` varchar(128) collateutf8_czech_ci NOT NULL,644 `price` int(11) NOT NULL default'0',645 `count` int(11) NOT NULL default'1',646 `date` date NOT NULL default'0000-00-00',647 `segment` int(11) NOT NULL default'0',648 `used` int(11) NOT NULL default'0',649 `consumption` int(11) NOT NULL default'0',650 `user` int(11) NOT NULL default'0',651 `info` text collateutf8_czech_ci NOT NULL,652 `channel` int(11) NOT NULL default'0',653 `device_id` varchar(255) collateutf8_czech_ci NOT NULL,654 `shop` varchar(64) collateutf8_czech_ci NOT NULL,655 `deprecated_price` int(11) NOT NULL default'0',656 `TimeEnlistment` datetime NOT NULL default'0000-00-00 00:00:00',657 `TimeElimination` datetime NOT NULL default'0000-00-00 00:00:00',769 `id` int(11) NOT NULL AUTO_INCREMENT, 770 `name` varchar(128) COLLATE utf8_czech_ci NOT NULL, 771 `price` int(11) NOT NULL DEFAULT '0', 772 `count` int(11) NOT NULL DEFAULT '1', 773 `date` date NOT NULL DEFAULT '0000-00-00', 774 `segment` int(11) NOT NULL DEFAULT '0', 775 `used` int(11) NOT NULL DEFAULT '0', 776 `consumption` int(11) NOT NULL DEFAULT '0', 777 `user` int(11) NOT NULL DEFAULT '0', 778 `info` text COLLATE utf8_czech_ci NOT NULL, 779 `channel` int(11) NOT NULL DEFAULT '0', 780 `device_id` varchar(255) COLLATE utf8_czech_ci NOT NULL, 781 `shop` varchar(64) COLLATE utf8_czech_ci NOT NULL, 782 `deprecated_price` int(11) NOT NULL DEFAULT '0', 783 `TimeEnlistment` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 784 `TimeElimination` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 658 785 `StockCard` int(11) NOT NULL, 659 PRIMARY KEY 660 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=162 ;786 PRIMARY KEY (`id`) 787 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=162 ; 661 788 662 789 -- -------------------------------------------------------- … … 667 794 668 795 CREATE TABLE IF NOT EXISTS `network_segments` ( 669 `id` int(11) NOT NULL auto_increment,670 `name` varchar(128) collateutf8_czech_ci NOT NULL,671 `price` int(11) NOT NULL default'0',672 `parent` int(11) NOT NULL default'0',673 `users` int(11) NOT NULL default'0',674 `consumption` int(11) NOT NULL default'0',675 `users_overheads` int(11) NOT NULL default'0',676 PRIMARY KEY 677 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=33 ;796 `id` int(11) NOT NULL AUTO_INCREMENT, 797 `name` varchar(128) COLLATE utf8_czech_ci NOT NULL, 798 `price` int(11) NOT NULL DEFAULT '0', 799 `parent` int(11) NOT NULL DEFAULT '0', 800 `users` int(11) NOT NULL DEFAULT '0', 801 `consumption` int(11) NOT NULL DEFAULT '0', 802 `users_overheads` int(11) NOT NULL DEFAULT '0', 803 PRIMARY KEY (`id`) 804 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=33 ; 678 805 679 806 -- -------------------------------------------------------- … … 684 811 685 812 CREATE TABLE IF NOT EXISTS `News` ( 686 `Id` int(11) NOT NULL auto_increment, 687 `Title` varchar(255) collate utf8_czech_ci NOT NULL, 688 `Content` text collate utf8_czech_ci NOT NULL, 689 `Date` datetime NOT NULL default '0000-00-00 00:00:00', 690 `TargetDate` datetime NOT NULL default '0000-00-00 00:00:00', 691 `Author` varchar(32) collate utf8_czech_ci NOT NULL, 692 `IP` varchar(16) collate utf8_czech_ci NOT NULL, 693 `Category` int(11) NOT NULL default '0', 694 `Enclosure` varchar(255) collate utf8_czech_ci NOT NULL, 695 `User` int(11) NOT NULL default '0', 696 PRIMARY KEY (`Id`), 813 `Id` int(11) NOT NULL AUTO_INCREMENT, 814 `Title` varchar(255) COLLATE utf8_czech_ci NOT NULL, 815 `Content` text COLLATE utf8_czech_ci NOT NULL, 816 `Date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 817 `TargetDate` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 818 `Author` varchar(32) COLLATE utf8_czech_ci NOT NULL, 819 `IP` varchar(16) COLLATE utf8_czech_ci NOT NULL, 820 `Category` int(11) DEFAULT '0', 821 `Enclosure` varchar(255) COLLATE utf8_czech_ci NOT NULL, 822 `User` int(11) NOT NULL DEFAULT '0', 823 `Link` varchar(255) COLLATE utf8_czech_ci NOT NULL, 824 PRIMARY KEY (`Id`), 697 825 KEY `category` (`Category`), 698 KEY `date` (`Date`) 699 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=30935 ; 826 KEY `date` (`Date`), 827 KEY `Title` (`Title`), 828 KEY `Link` (`Link`) 829 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=34316 ; 700 830 701 831 -- -------------------------------------------------------- … … 706 836 707 837 CREATE TABLE IF NOT EXISTS `NewsCategory` ( 708 `Id` int(11) NOT NULL auto_increment, 709 `Caption` varchar(255) collate utf8_czech_ci NOT NULL, 710 `Permission` int(11) NOT NULL default '0', 711 PRIMARY KEY (`Id`) 712 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=14 ; 838 `Id` int(11) NOT NULL AUTO_INCREMENT, 839 `Caption` varchar(255) COLLATE utf8_czech_ci NOT NULL, 840 `Permission` int(11) NOT NULL DEFAULT '0', 841 `Sequence` int(11) NOT NULL, 842 `Group` int(11) NOT NULL DEFAULT '1', 843 `RSS` varchar(255) COLLATE utf8_czech_ci NOT NULL, 844 PRIMARY KEY (`Id`), 845 KEY `Sequence` (`Sequence`), 846 KEY `Group` (`Group`) 847 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=17 ; 713 848 714 849 -- -------------------------------------------------------- … … 719 854 720 855 CREATE TABLE IF NOT EXISTS `Panel` ( 721 `Id` int(11) NOT NULL auto_increment,722 `Module` varchar(255) collateutf8_czech_ci NOT NULL,723 `Parameters` varchar(255) collateutf8_czech_ci NOT NULL,856 `Id` int(11) NOT NULL AUTO_INCREMENT, 857 `Module` varchar(255) COLLATE utf8_czech_ci NOT NULL, 858 `Parameters` varchar(255) COLLATE utf8_czech_ci NOT NULL, 724 859 `Order` int(11) NOT NULL, 725 860 `PanelColumn` int(11) NOT NULL, 726 PRIMARY KEY 861 PRIMARY KEY (`Id`), 727 862 KEY `PanelColumn` (`PanelColumn`) 728 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 2;863 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=14 ; 729 864 730 865 -- -------------------------------------------------------- … … 735 870 736 871 CREATE TABLE IF NOT EXISTS `PanelColumn` ( 737 `Id` int(11) NOT NULL auto_increment,738 `Width` varchar(255) collateutf8_czech_ci NOT NULL,739 PRIMARY KEY 740 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT= 5;872 `Id` int(11) NOT NULL AUTO_INCREMENT, 873 `Width` varchar(255) COLLATE utf8_czech_ci NOT NULL, 874 PRIMARY KEY (`Id`) 875 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=4 ; 741 876 742 877 -- -------------------------------------------------------- … … 747 882 748 883 CREATE TABLE IF NOT EXISTS `PermissionGroup` ( 749 `Id` int(11) NOT NULL auto_increment,750 `Description` varchar(255) collate utf8_czech_ci NOT NULL default'',751 PRIMARY KEY 752 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6 ;884 `Id` int(11) NOT NULL AUTO_INCREMENT, 885 `Description` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 886 PRIMARY KEY (`Id`) 887 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=6 ; 753 888 754 889 -- -------------------------------------------------------- … … 759 894 760 895 CREATE TABLE IF NOT EXISTS `PermissionGroupAssignment` ( 761 `Group` int(11) NOT NULL default '0', 762 `GroupOrOperation` int(11) NOT NULL default '0', 763 `Type` enum('Group','Operation') collate utf8_czech_ci NOT NULL default 'Group' 764 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 896 `Group` int(11) NOT NULL DEFAULT '0', 897 `GroupOrOperation` int(11) NOT NULL DEFAULT '0', 898 `Type` enum('Group','Operation') COLLATE utf8_czech_ci NOT NULL DEFAULT 'Group', 899 KEY `Group` (`Group`) 900 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 765 901 766 902 -- -------------------------------------------------------- … … 771 907 772 908 CREATE TABLE IF NOT EXISTS `PermissionOperation` ( 773 `Id` int(11) NOT NULL auto_increment,774 `Module` varchar(64) collate utf8_czech_ci NOT NULL default'',775 `Operation` varchar(128) collate utf8_czech_ci NOT NULL default'',776 `Item` varchar(64) collate utf8_czech_ci NOT NULL default'',777 `ItemId` int(11) NOT NULL default'0',778 PRIMARY KEY 779 ) ENGINE= MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=40;909 `Id` int(11) NOT NULL AUTO_INCREMENT, 910 `Module` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 911 `Operation` varchar(128) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 912 `Item` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 913 `ItemId` int(11) NOT NULL DEFAULT '0', 914 PRIMARY KEY (`Id`) 915 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=44 ; 780 916 781 917 -- -------------------------------------------------------- … … 786 922 787 923 CREATE TABLE IF NOT EXISTS `PermissionUserAssignment` ( 788 `User` int(11) NOT NULL default '0', 789 `GroupOrOperation` int(11) NOT NULL default '0', 790 `Type` enum('Group','Operation') collate utf8_czech_ci NOT NULL default 'Group' 791 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 924 `User` int(11) NOT NULL DEFAULT '0', 925 `GroupOrOperation` int(11) NOT NULL DEFAULT '0', 926 `Type` enum('Group','Operation') COLLATE utf8_czech_ci NOT NULL DEFAULT 'Group', 927 KEY `User` (`User`), 928 KEY `GroupOrOperation` (`GroupOrOperation`) 929 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 930 931 -- -------------------------------------------------------- 932 933 -- 934 -- Struktura tabulky `PhoneBook` 935 -- 936 937 CREATE TABLE IF NOT EXISTS `PhoneBook` ( 938 `Id` int(11) NOT NULL AUTO_INCREMENT, 939 `Number` varchar(255) COLLATE utf8_czech_ci NOT NULL, 940 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 941 `Address` varchar(255) COLLATE utf8_czech_ci NOT NULL, 942 `LastUpdate` datetime NOT NULL, 943 `Operator` varchar(255) COLLATE utf8_czech_ci NOT NULL, 944 PRIMARY KEY (`Id`) 945 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=53 ; 946 947 -- -------------------------------------------------------- 948 949 -- 950 -- Struktura tabulky `Service` 951 -- 952 953 CREATE TABLE IF NOT EXISTS `Service` ( 954 `Id` int(11) NOT NULL AUTO_INCREMENT, 955 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 956 PRIMARY KEY (`Id`) 957 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 792 958 793 959 -- -------------------------------------------------------- … … 798 964 799 965 CREATE TABLE IF NOT EXISTS `StockCard` ( 800 `Id` int(11) NOT NULL auto_increment,801 `Name` varchar(255) collateutf8_czech_ci NOT NULL,966 `Id` int(11) NOT NULL AUTO_INCREMENT, 967 `Name` varchar(255) COLLATE utf8_czech_ci NOT NULL, 802 968 `SellPrice` float NOT NULL, 803 969 `Consumption` int(11) NOT NULL COMMENT 'In Watts', 804 PRIMARY KEY 805 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ;970 PRIMARY KEY (`Id`) 971 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=1 ; 806 972 807 973 -- -------------------------------------------------------- … … 812 978 813 979 CREATE TABLE IF NOT EXISTS `Subject` ( 814 `Id` int(11) NOT NULL auto_increment, 815 `Name` varchar(64) collate utf8_czech_ci NOT NULL default '', 816 `AddressStreet` varchar(64) collate utf8_czech_ci NOT NULL default '', 817 `AddressTown` varchar(64) collate utf8_czech_ci NOT NULL default '', 818 `AddressPSC` int(11) NOT NULL default '0', 819 `IC` varchar(32) collate utf8_czech_ci NOT NULL, 820 `DIC` varchar(32) collate utf8_czech_ci NOT NULL default '', 821 `MapPositionX` float NOT NULL default '0', 822 `MapPositionY` float NOT NULL default '0', 823 `WWW` varchar(255) collate utf8_czech_ci NOT NULL, 824 `Note` varchar(255) collate utf8_czech_ci NOT NULL, 825 PRIMARY KEY (`Id`) 826 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=117 ; 980 `Id` int(11) NOT NULL AUTO_INCREMENT, 981 `Name` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 982 `AddressStreet` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 983 `AddressTown` varchar(64) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 984 `AddressPSC` int(11) NOT NULL DEFAULT '0', 985 `AddressCountry` varchar(255) COLLATE utf8_czech_ci NOT NULL, 986 `IC` varchar(32) COLLATE utf8_czech_ci NOT NULL, 987 `DIC` varchar(32) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 988 `MapPositionX` float NOT NULL DEFAULT '0', 989 `MapPositionY` float NOT NULL DEFAULT '0', 990 `WWW` varchar(255) COLLATE utf8_czech_ci NOT NULL, 991 `Note` varchar(255) COLLATE utf8_czech_ci NOT NULL, 992 PRIMARY KEY (`Id`) 993 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=182 ; 827 994 828 995 -- -------------------------------------------------------- … … 833 1000 834 1001 CREATE TABLE IF NOT EXISTS `SubjectOpenTime` ( 835 `Subject` int(11) NOT NULL default'0',836 `UpdateTime` datetime NOT NULL default'0000-00-00 00:00:00',837 `Notice` varchar(255) collate utf8_czech_ci NOT NULL default'',1002 `Subject` int(11) NOT NULL DEFAULT '0', 1003 `UpdateTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 1004 `Notice` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 838 1005 `Photo` int(11) NOT NULL, 839 PRIMARY KEY(`Subject`)840 ) ENGINE= MyISAMDEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci;1006 KEY `Subject` (`Subject`) 1007 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 841 1008 842 1009 -- -------------------------------------------------------- … … 854 1021 `Close2` int(11) NOT NULL, 855 1022 KEY `Subject` (`Subject`) 856 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 857 858 -- -------------------------------------------------------- 859 860 -- 861 -- Struktura tabulky `Task` 862 -- 863 864 CREATE TABLE IF NOT EXISTS `Task` ( 865 `Id` int(11) NOT NULL auto_increment, 866 `TimeCreate` datetime NOT NULL, 867 `TimeFinished` datetime default NULL, 868 `Description` text collate utf8_czech_ci NOT NULL, 869 `Conclusion` text collate utf8_czech_ci NOT NULL, 870 PRIMARY KEY (`Id`), 871 KEY `TimeCreate` (`TimeCreate`), 872 KEY `TimeFinished` (`TimeFinished`) 873 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=13 ; 874 875 -- -------------------------------------------------------- 876 877 -- 878 -- Struktura tabulky `TKR` 879 -- 880 881 CREATE TABLE IF NOT EXISTS `TKR` ( 882 `Id` int(11) NOT NULL auto_increment, 883 `Name` varchar(16) collate utf8_czech_ci NOT NULL, 884 `Frequency` int(11) NOT NULL default '0', 885 `Norm` varchar(8) collate utf8_czech_ci NOT NULL, 886 `Homepage` varchar(255) collate utf8_czech_ci NOT NULL, 887 `Language` varchar(32) collate utf8_czech_ci NOT NULL, 888 `ShortName` varchar(16) collate utf8_czech_ci NOT NULL, 889 PRIMARY KEY (`Id`) 890 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=25 ; 1023 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci; 1024 1025 -- -------------------------------------------------------- 1026 1027 -- 1028 -- Struktura tabulky `TV` 1029 -- 1030 1031 CREATE TABLE IF NOT EXISTS `TV` ( 1032 `Id` int(11) NOT NULL AUTO_INCREMENT, 1033 `Name` varchar(16) COLLATE utf8_czech_ci NOT NULL, 1034 `Frequency` int(11) NOT NULL DEFAULT '0', 1035 `Norm` varchar(8) COLLATE utf8_czech_ci NOT NULL, 1036 `Homepage` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1037 `Language` varchar(32) COLLATE utf8_czech_ci NOT NULL, 1038 `ShortName` varchar(16) COLLATE utf8_czech_ci NOT NULL, 1039 `Stream` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1040 `StreamWeb` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1041 `SourceType` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1042 `Category` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1043 PRIMARY KEY (`Id`) 1044 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=43 ; 891 1045 892 1046 -- -------------------------------------------------------- … … 897 1051 898 1052 CREATE TABLE IF NOT EXISTS `User` ( 899 `Id` int(11) NOT NULL auto_increment,900 `Login` varchar(64) collateutf8_czech_ci NOT NULL,901 `Name` varchar(128) collateutf8_czech_ci NOT NULL,902 `Password` varchar(255) collateutf8_czech_ci NOT NULL,903 `Email` varchar(128) collate utf8_czech_ci NOT NULL default'',904 `LastIpAddress` varchar(16) collate utf8_czech_ci NOT NULL default'',905 `LastLoginTime` datetime NOT NULL default'0000-00-00 00:00:00',906 `RegistrationTime` datetime NOT NULL default'0000-00-00 00:00:00',907 `Member` int(11) NOT NULL,908 `Locked` tinyint(1) NOT NULL default'0',909 `ICQ` int(11) NOT NULL default'0',910 `PhoneNumber` varchar(32) collate utf8_czech_ci NOT NULL default'',911 `InitPassword` varchar(255) collateutf8_czech_ci NOT NULL,912 PRIMARY KEY 1053 `Id` int(11) NOT NULL AUTO_INCREMENT, 1054 `Login` varchar(64) COLLATE utf8_czech_ci NOT NULL, 1055 `Name` varchar(128) COLLATE utf8_czech_ci NOT NULL, 1056 `Password` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1057 `Email` varchar(128) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1058 `LastIpAddress` varchar(16) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1059 `LastLoginTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 1060 `RegistrationTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 1061 `Member` int(11) DEFAULT NULL, 1062 `Locked` tinyint(1) NOT NULL DEFAULT '0', 1063 `ICQ` int(11) NOT NULL DEFAULT '0', 1064 `PhoneNumber` varchar(32) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1065 `InitPassword` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1066 PRIMARY KEY (`Id`), 913 1067 UNIQUE KEY `Name` (`Login`), 914 UNIQUE KEY `Nick` (`Name`) 915 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=111 ; 1068 UNIQUE KEY `Nick` (`Name`), 1069 KEY `Member` (`Member`) 1070 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=207 ; 916 1071 917 1072 -- -------------------------------------------------------- … … 922 1077 923 1078 CREATE TABLE IF NOT EXISTS `UserOnline` ( 924 `Id` int(11) NOT NULL auto_increment,925 `User` int(11) NOT NULL default '0',926 `ActivityTime` datetime NOT NULL default'0000-00-00 00:00:00',927 `LoginTime` datetime NOT NULL default'0000-00-00 00:00:00',928 `SessionId` varchar(255) collate utf8_czech_ci NOT NULL default'',929 `IpAddress` varchar(16) collate utf8_czech_ci NOT NULL default'',930 `HostName` varchar(255) collate utf8_czech_ci NOT NULL default'',931 `ScriptName` varchar(255) collateutf8_czech_ci NOT NULL,932 PRIMARY KEY 1079 `Id` int(11) NOT NULL AUTO_INCREMENT, 1080 `User` int(11) NOT NULL DEFAULT '0' COMMENT 'User.Id', 1081 `ActivityTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 1082 `LoginTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', 1083 `SessionId` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1084 `IpAddress` varchar(16) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1085 `HostName` varchar(255) COLLATE utf8_czech_ci NOT NULL DEFAULT '', 1086 `ScriptName` varchar(255) COLLATE utf8_czech_ci NOT NULL, 1087 PRIMARY KEY (`Id`), 933 1088 KEY `User` (`User`) 934 ) ENGINE=M yISAM DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=25044;1089 ) ENGINE=MEMORY DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci AUTO_INCREMENT=2236 ; 935 1090 936 1091 -- 937 1092 -- Omezení pro exportované tabulky 938 1093 -- 1094 1095 -- 1096 -- Omezení pro tabulku `DocumentLineSequence` 1097 -- 1098 ALTER TABLE `DocumentLineSequence` 1099 ADD CONSTRAINT `DocumentLineSequence_ibfk_1` FOREIGN KEY (`DocumentLine`) REFERENCES `DocumentLine` (`Id`), 1100 ADD CONSTRAINT `DocumentLineSequence_ibfk_2` FOREIGN KEY (`FinanceYear`) REFERENCES `FinanceYear` (`Id`); 1101 1102 -- 1103 -- Omezení pro tabulku `FinanceBills` 1104 -- 1105 ALTER TABLE `FinanceBills` 1106 ADD CONSTRAINT `FinanceBills_ibfk_1` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`); 1107 1108 -- 1109 -- Omezení pro tabulku `FinanceBillsItems` 1110 -- 1111 ALTER TABLE `FinanceBillsItems` 1112 ADD CONSTRAINT `FinanceBillsItems_ibfk_1` FOREIGN KEY (`Bill`) REFERENCES `FinanceBills` (`Id`); 1113 1114 -- 1115 -- Omezení pro tabulku `FinanceClaimsLiabilities` 1116 -- 1117 ALTER TABLE `FinanceClaimsLiabilities` 1118 ADD CONSTRAINT `FinanceClaimsLiabilities_ibfk_1` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`); 1119 1120 -- 1121 -- Omezení pro tabulku `FinanceOperation` 1122 -- 1123 ALTER TABLE `FinanceOperation` 1124 ADD CONSTRAINT `FinanceOperation_ibfk_1` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`), 1125 ADD CONSTRAINT `FinanceOperation_ibfk_2` FOREIGN KEY (`Bill`) REFERENCES `FinanceBills` (`Id`); 939 1126 940 1127 -- … … 945 1132 946 1133 -- 1134 -- Omezení pro tabulku `Log` 1135 -- 1136 ALTER TABLE `Log` 1137 ADD CONSTRAINT `Log_ibfk_1` FOREIGN KEY (`User`) REFERENCES `User` (`Id`); 1138 1139 -- 1140 -- Omezení pro tabulku `Member` 1141 -- 1142 ALTER TABLE `Member` 1143 ADD CONSTRAINT `Member_ibfk_10` FOREIGN KEY (`InternetTariffNextMonth`) REFERENCES `FinanceTariff` (`Tariff`), 1144 ADD CONSTRAINT `Member_ibfk_11` FOREIGN KEY (`BillingPeriod`) REFERENCES `FinanceBillingPeriod` (`Id`), 1145 ADD CONSTRAINT `Member_ibfk_12` FOREIGN KEY (`BillingPeriodNext`) REFERENCES `FinanceBillingPeriod` (`Id`), 1146 ADD CONSTRAINT `Member_ibfk_7` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`), 1147 ADD CONSTRAINT `Member_ibfk_8` FOREIGN KEY (`ResponsibleUser`) REFERENCES `User` (`Id`), 1148 ADD CONSTRAINT `Member_ibfk_9` FOREIGN KEY (`InternetTariffCurrentMonth`) REFERENCES `FinanceTariff` (`Tariff`); 1149 1150 -- 1151 -- Omezení pro tabulku `MemberPayment` 1152 -- 1153 ALTER TABLE `MemberPayment` 1154 ADD CONSTRAINT `MemberPayment_ibfk_1` FOREIGN KEY (`Member`) REFERENCES `Member` (`Id`); 1155 1156 -- 1157 -- Omezení pro tabulku `NetworkAP` 1158 -- 1159 ALTER TABLE `NetworkAP` 1160 ADD CONSTRAINT `NetworkAP_ibfk_1` FOREIGN KEY (`NetworkDevice`) REFERENCES `NetworkDevice` (`Id`); 1161 1162 -- 1163 -- Omezení pro tabulku `NetworkDevice` 1164 -- 1165 ALTER TABLE `NetworkDevice` 1166 ADD CONSTRAINT `NetworkDevice_ibfk_4` FOREIGN KEY (`Member`) REFERENCES `Member` (`Id`), 1167 ADD CONSTRAINT `NetworkDevice_ibfk_5` FOREIGN KEY (`Location`) REFERENCES `Member` (`Id`), 1168 ADD CONSTRAINT `NetworkDevice_ibfk_6` FOREIGN KEY (`Type`) REFERENCES `NetworkDeviceType` (`Id`); 1169 1170 -- 1171 -- Omezení pro tabulku `NetworkFirewall` 1172 -- 1173 ALTER TABLE `NetworkFirewall` 1174 ADD CONSTRAINT `NetworkFirewall_ibfk_1` FOREIGN KEY (`NetworkDevice`) REFERENCES `NetworkDevice` (`Id`); 1175 1176 -- 1177 -- Omezení pro tabulku `NetworkInterface` 1178 -- 1179 ALTER TABLE `NetworkInterface` 1180 ADD CONSTRAINT `NetworkInterface_ibfk_1` FOREIGN KEY (`Type`) REFERENCES `NetworkInterfaceType` (`Id`), 1181 ADD CONSTRAINT `NetworkInterface_ibfk_2` FOREIGN KEY (`Device`) REFERENCES `NetworkDevice` (`Id`); 1182 1183 -- 1184 -- Omezení pro tabulku `NetworkSubnet` 1185 -- 1186 ALTER TABLE `NetworkSubnet` 1187 ADD CONSTRAINT `NetworkSubnet_ibfk_1` FOREIGN KEY (`Member`) REFERENCES `Member` (`Id`); 1188 1189 -- 1190 -- Omezení pro tabulku `News` 1191 -- 1192 ALTER TABLE `News` 1193 ADD CONSTRAINT `News_ibfk_1` FOREIGN KEY (`Category`) REFERENCES `NewsCategory` (`Id`); 1194 1195 -- 947 1196 -- Omezení pro tabulku `Panel` 948 1197 -- 949 1198 ALTER TABLE `Panel` 950 1199 ADD CONSTRAINT `Panel_ibfk_1` FOREIGN KEY (`PanelColumn`) REFERENCES `PanelColumn` (`Id`); 1200 1201 -- 1202 -- Omezení pro tabulku `PermissionUserAssignment` 1203 -- 1204 ALTER TABLE `PermissionUserAssignment` 1205 ADD CONSTRAINT `PermissionUserAssignment_ibfk_1` FOREIGN KEY (`User`) REFERENCES `User` (`Id`); 1206 1207 -- 1208 -- Omezení pro tabulku `SubjectOpenTime` 1209 -- 1210 ALTER TABLE `SubjectOpenTime` 1211 ADD CONSTRAINT `SubjectOpenTime_ibfk_1` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`); 1212 1213 -- 1214 -- Omezení pro tabulku `SubjectOpenTimeDay` 1215 -- 1216 ALTER TABLE `SubjectOpenTimeDay` 1217 ADD CONSTRAINT `SubjectOpenTimeDay_ibfk_1` FOREIGN KEY (`Subject`) REFERENCES `Subject` (`Id`); 1218 1219 -- 1220 -- Omezení pro tabulku `User` 1221 -- 1222 ALTER TABLE `User` 1223 ADD CONSTRAINT `User_ibfk_1` FOREIGN KEY (`Member`) REFERENCES `Member` (`Id`);
Note:
See TracChangeset
for help on using the changeset viewer.