[BUGFIX] Reduce length of identifier key in sys_file_processedfile
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / ext_tables.sql
1 #
2
3 #
4 # Table structure for table 'be_groups'
5 #
6 CREATE TABLE be_groups (
7 uid int(11) unsigned NOT NULL auto_increment,
8 pid int(11) unsigned DEFAULT '0' NOT NULL,
9 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
10 title varchar(50) DEFAULT '' NOT NULL,
11 non_exclude_fields text,
12 explicit_allowdeny text,
13 allowed_languages varchar(255) DEFAULT '' NOT NULL,
14 custom_options text,
15 db_mountpoints text,
16 pagetypes_select varchar(255) DEFAULT '' NOT NULL,
17 tables_select text,
18 tables_modify text,
19 crdate int(11) unsigned DEFAULT '0' NOT NULL,
20 cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
21 groupMods text,
22 file_mountpoints text,
23 file_permissions text,
24 hidden tinyint(1) unsigned DEFAULT '0' NOT NULL,
25 description text,
26 lockToDomain varchar(50) DEFAULT '' NOT NULL,
27 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
28 TSconfig text,
29 subgroup text,
30 hide_in_lists tinyint(4) DEFAULT '0' NOT NULL,
31 workspace_perms tinyint(3) DEFAULT '1' NOT NULL,
32 category_perms varchar(255) DEFAULT '' NOT NULL,
33 PRIMARY KEY (uid),
34 KEY parent (pid)
35 );
36
37 #
38 # Table structure for table 'be_sessions'
39 #
40 CREATE TABLE be_sessions (
41 ses_id varchar(32) DEFAULT '' NOT NULL,
42 ses_name varchar(32) DEFAULT '' NOT NULL,
43 ses_iplock varchar(39) DEFAULT '' NOT NULL,
44 ses_hashlock int(11) DEFAULT '0' NOT NULL,
45 ses_userid int(11) unsigned DEFAULT '0' NOT NULL,
46 ses_tstamp int(11) unsigned DEFAULT '0' NOT NULL,
47 ses_data longtext,
48 ses_backuserid int(11) NOT NULL default '0',
49 PRIMARY KEY (ses_id,ses_name),
50 KEY ses_tstamp (ses_tstamp)
51 );
52
53 #
54 # Table structure for table 'be_users'
55 #
56 CREATE TABLE be_users (
57 uid int(11) unsigned NOT NULL auto_increment,
58 pid int(11) unsigned DEFAULT '0' NOT NULL,
59 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
60 username varchar(50) DEFAULT '' NOT NULL,
61 password varchar(100) DEFAULT '' NOT NULL,
62 admin tinyint(4) unsigned DEFAULT '0' NOT NULL,
63 usergroup varchar(255) DEFAULT '' NOT NULL,
64 disable tinyint(1) unsigned DEFAULT '0' NOT NULL,
65 starttime int(11) unsigned DEFAULT '0' NOT NULL,
66 endtime int(11) unsigned DEFAULT '0' NOT NULL,
67 lang char(2) DEFAULT '' NOT NULL,
68 email varchar(80) DEFAULT '' NOT NULL,
69 db_mountpoints text,
70 options tinyint(4) unsigned DEFAULT '0' NOT NULL,
71 crdate int(11) unsigned DEFAULT '0' NOT NULL,
72 cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
73 realName varchar(80) DEFAULT '' NOT NULL,
74 userMods text,
75 allowed_languages varchar(255) DEFAULT '' NOT NULL,
76 uc mediumtext,
77 file_mountpoints text,
78 file_permissions text,
79 workspace_perms tinyint(3) DEFAULT '1' NOT NULL,
80 lockToDomain varchar(50) DEFAULT '' NOT NULL,
81 disableIPlock tinyint(1) unsigned DEFAULT '0' NOT NULL,
82 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
83 TSconfig text,
84 lastlogin int(10) unsigned DEFAULT '0' NOT NULL,
85 createdByAction int(11) DEFAULT '0' NOT NULL,
86 usergroup_cached_list text,
87 workspace_id int(11) DEFAULT '0' NOT NULL,
88 workspace_preview tinyint(3) DEFAULT '1' NOT NULL,
89 category_perms varchar(255) DEFAULT '' NOT NULL,
90 PRIMARY KEY (uid),
91 KEY parent (pid),
92 KEY username (username)
93 );
94
95 #
96 # Table structure for table 'cache_imagesizes'
97 #
98 CREATE TABLE cache_imagesizes (
99 md5hash varchar(32) DEFAULT '' NOT NULL,
100 md5filename varchar(32) DEFAULT '' NOT NULL,
101 tstamp int(11) DEFAULT '0' NOT NULL,
102 filename varchar(255) DEFAULT '' NOT NULL,
103 imagewidth mediumint(11) unsigned DEFAULT '0' NOT NULL,
104 imageheight mediumint(11) unsigned DEFAULT '0' NOT NULL,
105 PRIMARY KEY (md5filename)
106 ) ENGINE=InnoDB;
107
108 #
109 # Table structure for table 'pages'
110 #
111 CREATE TABLE pages (
112 uid int(11) NOT NULL auto_increment,
113 pid int(11) DEFAULT '0' NOT NULL,
114 t3ver_oid int(11) DEFAULT '0' NOT NULL,
115 t3ver_id int(11) DEFAULT '0' NOT NULL,
116 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
117 t3ver_label varchar(255) DEFAULT '' NOT NULL,
118 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
119 t3ver_stage int(11) DEFAULT '0' NOT NULL,
120 t3ver_count int(11) DEFAULT '0' NOT NULL,
121 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
122 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
123 t3_origuid int(11) DEFAULT '0' NOT NULL,
124 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
125 sorting int(11) unsigned DEFAULT '0' NOT NULL,
126 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
127 perms_userid int(11) unsigned DEFAULT '0' NOT NULL,
128 perms_groupid int(11) unsigned DEFAULT '0' NOT NULL,
129 perms_user tinyint(4) unsigned DEFAULT '0' NOT NULL,
130 perms_group tinyint(4) unsigned DEFAULT '0' NOT NULL,
131 perms_everybody tinyint(4) unsigned DEFAULT '0' NOT NULL,
132 editlock tinyint(4) unsigned DEFAULT '0' NOT NULL,
133 crdate int(11) unsigned DEFAULT '0' NOT NULL,
134 cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
135 hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
136 title varchar(255) DEFAULT '' NOT NULL,
137 doktype int(11) unsigned DEFAULT '0' NOT NULL,
138 TSconfig text,
139 storage_pid int(11) DEFAULT '0' NOT NULL,
140 is_siteroot tinyint(4) DEFAULT '0' NOT NULL,
141 php_tree_stop tinyint(4) DEFAULT '0' NOT NULL,
142 tx_impexp_origuid int(11) DEFAULT '0' NOT NULL,
143 url varchar(255) DEFAULT '' NOT NULL,
144 starttime int(11) unsigned DEFAULT '0' NOT NULL,
145 endtime int(11) unsigned DEFAULT '0' NOT NULL,
146 urltype tinyint(4) unsigned DEFAULT '0' NOT NULL,
147 shortcut int(10) unsigned DEFAULT '0' NOT NULL,
148 shortcut_mode int(10) unsigned DEFAULT '0' NOT NULL,
149 no_cache int(10) unsigned DEFAULT '0' NOT NULL,
150 fe_group varchar(100) DEFAULT '0' NOT NULL,
151 subtitle varchar(255) DEFAULT '' NOT NULL,
152 layout int(11) unsigned DEFAULT '0' NOT NULL,
153 url_scheme tinyint(3) unsigned DEFAULT '0' NOT NULL,
154 target varchar(80) DEFAULT '' NOT NULL,
155 media text,
156 lastUpdated int(10) unsigned DEFAULT '0' NOT NULL,
157 keywords text,
158 cache_timeout int(10) unsigned DEFAULT '0' NOT NULL,
159 cache_tags varchar(255) DEFAULT '' NOT NULL,
160 newUntil int(10) unsigned DEFAULT '0' NOT NULL,
161 description text,
162 no_search tinyint(3) unsigned DEFAULT '0' NOT NULL,
163 SYS_LASTCHANGED int(10) unsigned DEFAULT '0' NOT NULL,
164 abstract text,
165 module varchar(10) DEFAULT '' NOT NULL,
166 extendToSubpages tinyint(3) unsigned DEFAULT '0' NOT NULL,
167 author varchar(255) DEFAULT '' NOT NULL,
168 author_email varchar(80) DEFAULT '' NOT NULL,
169 nav_title varchar(255) DEFAULT '' NOT NULL,
170 nav_hide tinyint(4) DEFAULT '0' NOT NULL,
171 content_from_pid int(10) unsigned DEFAULT '0' NOT NULL,
172 mount_pid int(10) unsigned DEFAULT '0' NOT NULL,
173 mount_pid_ol tinyint(4) DEFAULT '0' NOT NULL,
174 alias varchar(32) DEFAULT '' NOT NULL,
175 l18n_cfg tinyint(4) DEFAULT '0' NOT NULL,
176 fe_login_mode tinyint(4) DEFAULT '0' NOT NULL,
177 backend_layout varchar(64) DEFAULT '' NOT NULL,
178 backend_layout_next_level varchar(64) DEFAULT '' NOT NULL,
179 PRIMARY KEY (uid),
180 KEY t3ver_oid (t3ver_oid,t3ver_wsid),
181 KEY parent (pid,deleted,sorting),
182 KEY alias (alias),
183 KEY determineSiteRoot (deleted,hidden,is_siteroot)
184 );
185
186 #
187 # Table structure for table 'sys_registry'
188 #
189 CREATE TABLE sys_registry (
190 uid int(11) unsigned NOT NULL auto_increment,
191 entry_namespace varchar(128) DEFAULT '' NOT NULL,
192 entry_key varchar(128) DEFAULT '' NOT NULL,
193 entry_value blob,
194 PRIMARY KEY (uid),
195 UNIQUE KEY entry_identifier (entry_namespace,entry_key)
196 );
197
198 #
199 # Table structure for table 'sys_be_shortcuts'
200 #
201 CREATE TABLE sys_be_shortcuts (
202 uid int(11) unsigned NOT NULL auto_increment,
203 userid int(11) unsigned DEFAULT '0' NOT NULL,
204 module_name varchar(255) DEFAULT '' NOT NULL,
205 url text,
206 description varchar(255) DEFAULT '' NOT NULL,
207 sorting int(11) DEFAULT '0' NOT NULL,
208 sc_group tinyint(4) DEFAULT '0' NOT NULL,
209 PRIMARY KEY (uid),
210 KEY event (userid)
211 );
212
213
214 #
215 # Table structure for table 'sys_news'
216 #
217 CREATE TABLE sys_news (
218 uid int(11) unsigned NOT NULL auto_increment,
219 pid int(11) unsigned DEFAULT '0' NOT NULL,
220 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
221 crdate int(11) unsigned DEFAULT '0' NOT NULL,
222 cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
223 deleted tinyint(3) unsigned DEFAULT '0' NOT NULL,
224 hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
225 starttime int(11) unsigned DEFAULT '0' NOT NULL,
226 endtime int(11) unsigned DEFAULT '0' NOT NULL,
227 title varchar(255) DEFAULT '' NOT NULL,
228 content mediumtext,
229
230 PRIMARY KEY (uid),
231 KEY parent (pid)
232 );
233
234
235 #
236 # Table structure for table 'sys_filemounts'
237 #
238 CREATE TABLE sys_filemounts (
239 uid int(11) unsigned NOT NULL auto_increment,
240 pid int(11) unsigned DEFAULT '0' NOT NULL,
241 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
242 title varchar(30) DEFAULT '' NOT NULL,
243 path varchar(120) DEFAULT '' NOT NULL,
244 base tinyint(4) unsigned DEFAULT '0' NOT NULL,
245 hidden tinyint(3) unsigned DEFAULT '0' NOT NULL,
246 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
247 sorting int(11) unsigned DEFAULT '0' NOT NULL,
248 PRIMARY KEY (uid),
249 KEY parent (pid)
250 );
251
252
253 #
254 # Table structure for table 'sys_file_storage'
255 #
256 CREATE TABLE sys_file_storage (
257 uid int(11) NOT NULL auto_increment,
258 pid int(11) DEFAULT '0' NOT NULL,
259 tstamp int(11) DEFAULT '0' NOT NULL,
260 crdate int(11) DEFAULT '0' NOT NULL,
261 cruser_id int(11) DEFAULT '0' NOT NULL,
262 deleted tinyint(4) DEFAULT '0' NOT NULL,
263 hidden tinyint(4) DEFAULT '0' NOT NULL,
264
265 name varchar(30) DEFAULT '' NOT NULL,
266 description text,
267 driver tinytext,
268 configuration text,
269 is_default tinyint(4) DEFAULT '0' NOT NULL,
270 is_browsable tinyint(4) DEFAULT '0' NOT NULL,
271 is_public tinyint(4) DEFAULT '0' NOT NULL,
272 is_writable tinyint(4) DEFAULT '0' NOT NULL,
273 is_online tinyint(4) DEFAULT '1' NOT NULL,
274 processingfolder tinytext,
275
276 PRIMARY KEY (uid),
277 KEY parent (pid,deleted),
278 KEY deleted_hidden (deleted,hidden)
279 );
280
281 #
282 # Table structure for table 'sys_file'
283 #
284 CREATE TABLE sys_file (
285 uid int(11) NOT NULL auto_increment,
286 pid int(11) DEFAULT '0' NOT NULL,
287 # update timestamp of the database record, not the file!
288 tstamp int(11) DEFAULT '0' NOT NULL,
289 last_indexed int(11) DEFAULT '0' NOT NULL,
290
291 # management information
292 missing tinyint(4) DEFAULT '0' NOT NULL,
293 storage int(11) DEFAULT '0' NOT NULL,
294 type varchar(10) DEFAULT '' NOT NULL,
295 metadata int(11) DEFAULT '0' NOT NULL,
296
297 # file info data
298 identifier text,
299 identifier_hash varchar(40) DEFAULT '' NOT NULL,
300 folder_hash varchar(40) DEFAULT '' NOT NULL,
301 extension varchar(255) DEFAULT '' NOT NULL,
302 mime_type varchar(255) DEFAULT '' NOT NULL,
303 name tinytext,
304 sha1 tinytext,
305 size int(11) DEFAULT '0' NOT NULL,
306 creation_date int(11) DEFAULT '0' NOT NULL,
307 modification_date int(11) DEFAULT '0' NOT NULL,
308
309 PRIMARY KEY (uid),
310 KEY sel01 (storage,identifier_hash),
311 KEY folder (storage,folder_hash),
312 KEY tstamp (tstamp),
313 KEY lastindex (last_indexed),
314 KEY sha1 (sha1(40))
315 );
316
317 #
318 # Table structure for table 'sys_file_metadata'
319 #
320 CREATE TABLE sys_file_metadata (
321 uid int(11) NOT NULL auto_increment,
322 pid int(11) DEFAULT '0' NOT NULL,
323 tstamp int(11) DEFAULT '0' NOT NULL,
324 crdate int(11) DEFAULT '0' NOT NULL,
325 cruser_id int(11) DEFAULT '0' NOT NULL,
326
327 # Language fields
328 sys_language_uid int(11) DEFAULT '0' NOT NULL,
329 l10n_parent int(11) DEFAULT '0' NOT NULL,
330 l10n_diffsource mediumblob NOT NULL,
331
332 # Versioning fields
333 t3ver_oid int(11) DEFAULT '0' NOT NULL,
334 t3ver_id int(11) DEFAULT '0' NOT NULL,
335 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
336 t3ver_label varchar(30) DEFAULT '' NOT NULL,
337 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
338 t3ver_stage int(11) DEFAULT '0' NOT NULL,
339 t3ver_count int(11) DEFAULT '0' NOT NULL,
340 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
341 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
342 t3_origuid int(11) DEFAULT '0' NOT NULL,
343
344 file int(11) DEFAULT '0' NOT NULL,
345 title tinytext,
346 width int(11) DEFAULT '0' NOT NULL,
347 height int(11) DEFAULT '0' NOT NULL,
348 description text,
349 alternative text,
350
351 PRIMARY KEY (uid),
352 KEY file (file),
353 KEY t3ver_oid (t3ver_oid,t3ver_wsid),
354 KEY fal_filelist (l10n_parent,sys_language_uid)
355 );
356
357
358 #
359 # Table structure for table 'sys_file_processedfile'.
360 # which is a "temporary" file, like an image preview
361 # This table does not have a TCA representation, as it is only written
362 # to using direct SQL queries in the code
363 #
364 CREATE TABLE sys_file_processedfile (
365 uid int(11) NOT NULL auto_increment,
366 tstamp int(11) DEFAULT '0' NOT NULL,
367 crdate int(11) DEFAULT '0' NOT NULL,
368
369 storage int(11) DEFAULT '0' NOT NULL,
370 original int(11) DEFAULT '0' NOT NULL,
371 identifier varchar(512) DEFAULT '' NOT NULL,
372 name tinytext,
373 configuration text,
374 configurationsha1 varchar(40) DEFAULT '' NOT NULL,
375 originalfilesha1 varchar(40) DEFAULT '' NOT NULL,
376 task_type varchar(200) DEFAULT '' NOT NULL,
377 checksum varchar(255) DEFAULT '' NOT NULL,
378 width int(11) DEFAULT '0',
379 height int(11) DEFAULT '0',
380
381 PRIMARY KEY (uid),
382 KEY combined_1 (original,task_type,configurationsha1),
383 KEY identifier (storage,identifier(200))
384 );
385
386 #
387 # Table structure for table 'sys_file_reference'
388 # which is one usage of a file with overloaded metadata
389 #
390 CREATE TABLE sys_file_reference (
391 uid int(11) NOT NULL auto_increment,
392 pid int(11) DEFAULT '0' NOT NULL,
393 tstamp int(11) DEFAULT '0' NOT NULL,
394 crdate int(11) DEFAULT '0' NOT NULL,
395 cruser_id int(11) DEFAULT '0' NOT NULL,
396 sorting int(10) DEFAULT '0' NOT NULL,
397 deleted tinyint(4) DEFAULT '0' NOT NULL,
398 hidden tinyint(4) DEFAULT '0' NOT NULL,
399
400 # Versioning fields
401 t3ver_oid int(11) DEFAULT '0' NOT NULL,
402 t3ver_id int(11) DEFAULT '0' NOT NULL,
403 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
404 t3ver_label varchar(30) DEFAULT '' NOT NULL,
405 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
406 t3ver_stage int(11) DEFAULT '0' NOT NULL,
407 t3ver_count int(11) DEFAULT '0' NOT NULL,
408 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
409 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
410 t3_origuid int(11) DEFAULT '0' NOT NULL,
411
412 # Language fields
413 sys_language_uid int(11) DEFAULT '0' NOT NULL,
414 l10n_parent int(11) DEFAULT '0' NOT NULL,
415 l10n_diffsource mediumblob NOT NULL,
416
417 # Reference fields (basically same as MM table)
418 uid_local int(11) DEFAULT '0' NOT NULL,
419 uid_foreign int(11) DEFAULT '0' NOT NULL,
420 tablenames varchar(64) DEFAULT '' NOT NULL,
421 fieldname varchar(64) DEFAULT '' NOT NULL,
422 sorting_foreign int(11) DEFAULT '0' NOT NULL,
423 table_local varchar(64) DEFAULT '' NOT NULL,
424
425 # Local usage overlay fields
426 title tinytext,
427 description text,
428 alternative tinytext,
429 link tinytext,
430 downloadname tinytext,
431
432 PRIMARY KEY (uid),
433 KEY parent (pid,deleted),
434 KEY tablenames_fieldname (tablenames(32),fieldname(12)),
435 KEY deleted (deleted),
436 KEY uid_foreign (uid_foreign)
437 );
438
439
440 #
441 # Table structure for table 'sys_file_collection'
442 #
443 CREATE TABLE sys_file_collection (
444 uid int(11) NOT NULL auto_increment,
445 pid int(11) DEFAULT '0' NOT NULL,
446 tstamp int(11) DEFAULT '0' NOT NULL,
447 crdate int(11) DEFAULT '0' NOT NULL,
448 cruser_id int(11) DEFAULT '0' NOT NULL,
449 t3ver_oid int(11) DEFAULT '0' NOT NULL,
450 t3ver_id int(11) DEFAULT '0' NOT NULL,
451 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
452 t3ver_label varchar(30) DEFAULT '' NOT NULL,
453 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
454 t3ver_stage int(11) DEFAULT '0' NOT NULL,
455 t3ver_count int(11) DEFAULT '0' NOT NULL,
456 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
457 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
458 t3_origuid int(11) DEFAULT '0' NOT NULL,
459 sys_language_uid int(11) DEFAULT '0' NOT NULL,
460 l10n_parent int(11) DEFAULT '0' NOT NULL,
461 l10n_diffsource mediumtext,
462 deleted tinyint(4) DEFAULT '0' NOT NULL,
463 hidden tinyint(4) DEFAULT '0' NOT NULL,
464 starttime int(11) DEFAULT '0' NOT NULL,
465 endtime int(11) DEFAULT '0' NOT NULL,
466
467 # Actual fields
468 title tinytext,
469 description text,
470 type varchar(30) DEFAULT 'static' NOT NULL,
471
472 # for type=static
473 files int(11) DEFAULT '0' NOT NULL,
474
475 # for type=folder:
476 storage int(11) DEFAULT '0' NOT NULL,
477 folder text NOT NULL,
478
479 # for type=category:
480 category int(11) DEFAULT '0' NOT NULL,
481
482 PRIMARY KEY (uid),
483 KEY parent (pid,deleted),
484 KEY t3ver_oid (t3ver_oid,t3ver_wsid)
485 );
486
487 #
488 # Table structure for table 'sys_collection'
489 #
490 CREATE TABLE sys_collection (
491 uid int(11) NOT NULL auto_increment,
492 pid int(11) DEFAULT '0' NOT NULL,
493 tstamp int(11) DEFAULT '0' NOT NULL,
494 crdate int(11) DEFAULT '0' NOT NULL,
495 cruser_id int(11) DEFAULT '0' NOT NULL,
496 t3ver_oid int(11) DEFAULT '0' NOT NULL,
497 t3ver_id int(11) DEFAULT '0' NOT NULL,
498 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
499 t3ver_label varchar(30) DEFAULT '' NOT NULL,
500 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
501 t3ver_stage int(11) DEFAULT '0' NOT NULL,
502 t3ver_count int(11) DEFAULT '0' NOT NULL,
503 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
504 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
505 t3_origuid int(11) DEFAULT '0' NOT NULL,
506 sys_language_uid int(11) DEFAULT '0' NOT NULL,
507 l10n_parent int(11) DEFAULT '0' NOT NULL,
508 l10n_diffsource mediumtext,
509 deleted tinyint(4) DEFAULT '0' NOT NULL,
510 hidden tinyint(4) DEFAULT '0' NOT NULL,
511 starttime int(11) DEFAULT '0' NOT NULL,
512 endtime int(11) DEFAULT '0' NOT NULL,
513 fe_group int(11) DEFAULT '0' NOT NULL,
514
515 title tinytext,
516 description text,
517 type varchar(32) DEFAULT 'static' NOT NULL,
518 table_name tinytext,
519 items int(11) DEFAULT '0' NOT NULL,
520
521 PRIMARY KEY (uid),
522 KEY parent (pid,deleted),
523 KEY t3ver_oid (t3ver_oid,t3ver_wsid)
524 );
525
526 #
527 # Table structure for table 'sys_collection_entries'
528 #
529 CREATE TABLE sys_collection_entries (
530 uid int(11) NOT NULL auto_increment,
531 uid_local int(11) DEFAULT '0' NOT NULL,
532 uid_foreign int(11) DEFAULT '0' NOT NULL,
533 tablenames varchar(30) DEFAULT '' NOT NULL,
534 sorting int(11) DEFAULT '0' NOT NULL,
535
536 KEY uid_local (uid_local),
537 KEY uid_foreign (uid_foreign),
538 PRIMARY KEY (uid)
539 );
540
541 #
542 # Table structure for table 'sys_history'
543 #
544 CREATE TABLE sys_history (
545 uid int(11) unsigned NOT NULL auto_increment,
546 pid int(11) unsigned DEFAULT '0' NOT NULL,
547 sys_log_uid int(11) DEFAULT '0' NOT NULL,
548 history_data mediumtext,
549 fieldlist text,
550 recuid int(11) DEFAULT '0' NOT NULL,
551 tablename varchar(255) DEFAULT '' NOT NULL,
552 tstamp int(11) DEFAULT '0' NOT NULL,
553 history_files mediumtext,
554 snapshot int(11) DEFAULT '0' NOT NULL,
555 PRIMARY KEY (uid),
556 KEY parent (pid),
557 KEY recordident_1 (tablename,recuid),
558 KEY recordident_2 (tablename,tstamp),
559 KEY sys_log_uid (sys_log_uid)
560 ) ENGINE=InnoDB;
561
562 #
563 # Table structure for table 'sys_lockedrecords'
564 #
565 CREATE TABLE sys_lockedrecords (
566 uid int(11) unsigned NOT NULL auto_increment,
567 userid int(11) unsigned DEFAULT '0' NOT NULL,
568 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
569 record_table varchar(255) DEFAULT '' NOT NULL,
570 record_uid int(11) DEFAULT '0' NOT NULL,
571 record_pid int(11) DEFAULT '0' NOT NULL,
572 username varchar(50) DEFAULT '' NOT NULL,
573 feuserid int(11) unsigned DEFAULT '0' NOT NULL,
574 PRIMARY KEY (uid),
575 KEY event (userid,tstamp)
576 );
577
578 #
579 # Table structure for table 'sys_refindex'
580 #
581 CREATE TABLE sys_refindex (
582 hash varchar(32) DEFAULT '' NOT NULL,
583 tablename varchar(255) DEFAULT '' NOT NULL,
584 recuid int(11) DEFAULT '0' NOT NULL,
585 field varchar(40) DEFAULT '' NOT NULL,
586 flexpointer varchar(255) DEFAULT '' NOT NULL,
587 softref_key varchar(30) DEFAULT '' NOT NULL,
588 softref_id varchar(40) DEFAULT '' NOT NULL,
589 sorting int(11) DEFAULT '0' NOT NULL,
590 deleted tinyint(1) DEFAULT '0' NOT NULL,
591 workspace int(11) DEFAULT '0' NOT NULL,
592 ref_table varchar(255) DEFAULT '' NOT NULL,
593 ref_uid int(11) DEFAULT '0' NOT NULL,
594 ref_string varchar(200) DEFAULT '' NOT NULL,
595
596 PRIMARY KEY (hash),
597 KEY lookup_rec (tablename,recuid),
598 KEY lookup_uid (ref_table,ref_uid),
599 KEY lookup_string (ref_string)
600 );
601
602 #
603 # Table structure for table 'sys_log'
604 #
605 CREATE TABLE sys_log (
606 uid int(11) unsigned NOT NULL auto_increment,
607 pid int(11) unsigned DEFAULT '0' NOT NULL,
608 userid int(11) unsigned DEFAULT '0' NOT NULL,
609 action tinyint(4) unsigned DEFAULT '0' NOT NULL,
610 recuid int(11) unsigned DEFAULT '0' NOT NULL,
611 tablename varchar(255) DEFAULT '' NOT NULL,
612 recpid int(11) DEFAULT '0' NOT NULL,
613 error tinyint(4) unsigned DEFAULT '0' NOT NULL,
614 details text NOT NULL,
615 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
616 type tinyint(3) unsigned DEFAULT '0' NOT NULL,
617 details_nr tinyint(3) unsigned DEFAULT '0' NOT NULL,
618 IP varchar(39) DEFAULT '' NOT NULL,
619 log_data text,
620 event_pid int(11) DEFAULT '-1' NOT NULL,
621 workspace int(11) DEFAULT '0' NOT NULL,
622 NEWid varchar(20) DEFAULT '' NOT NULL,
623 request_id varchar(13) DEFAULT '' NOT NULL,
624 time_micro float DEFAULT '0' NOT NULL,
625 component varchar(255) DEFAULT '' NOT NULL,
626 level tinyint(1) unsigned DEFAULT '0' NOT NULL,
627 message text,
628 data text,
629 PRIMARY KEY (uid),
630 KEY parent (pid),
631 KEY event (userid,event_pid),
632 KEY recuidIdx (recuid,uid),
633 KEY user_auth (type,action,tstamp),
634 KEY request (request_id)
635 ) ENGINE=InnoDB;
636
637 #
638 # Table structure for table 'sys_language'
639 #
640 CREATE TABLE sys_language (
641 uid int(11) unsigned NOT NULL auto_increment,
642 pid int(11) unsigned DEFAULT '0' NOT NULL,
643 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
644 hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
645 title varchar(80) DEFAULT '' NOT NULL,
646 flag varchar(20) DEFAULT '' NOT NULL,
647 static_lang_isocode int(11) unsigned DEFAULT '0' NOT NULL,
648 PRIMARY KEY (uid),
649 KEY parent (pid)
650 );
651
652 #
653 # Table structure for table 'sys_category'
654 #
655 CREATE TABLE sys_category (
656 uid int(11) NOT NULL auto_increment,
657 pid int(11) DEFAULT '0' NOT NULL,
658 tstamp int(11) DEFAULT '0' NOT NULL,
659 crdate int(11) DEFAULT '0' NOT NULL,
660 cruser_id int(11) DEFAULT '0' NOT NULL,
661 deleted tinyint(4) DEFAULT '0' NOT NULL,
662 hidden tinyint(4) DEFAULT '0' NOT NULL,
663 starttime int(11) unsigned DEFAULT '0' NOT NULL,
664 endtime int(11) unsigned DEFAULT '0' NOT NULL,
665
666 t3ver_oid int(11) DEFAULT '0' NOT NULL,
667 t3ver_id int(11) DEFAULT '0' NOT NULL,
668 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
669 t3ver_label varchar(30) DEFAULT '' NOT NULL,
670 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
671 t3ver_stage int(11) DEFAULT '0' NOT NULL,
672 t3ver_count int(11) DEFAULT '0' NOT NULL,
673 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
674 t3ver_move_id int(11) DEFAULT '0' NOT NULL,
675 t3_origuid int(11) DEFAULT '0' NOT NULL,
676 sorting int(11) unsigned DEFAULT '0' NOT NULL,
677
678 sys_language_uid int(11) DEFAULT '0' NOT NULL,
679 l10n_parent int(11) DEFAULT '0' NOT NULL,
680 l10n_diffsource mediumblob NOT NULL,
681
682 title tinytext NOT NULL,
683 description text NOT NULL,
684 parent int(11) DEFAULT '0' NOT NULL,
685 items int(11) DEFAULT '0' NOT NULL,
686
687 PRIMARY KEY (uid),
688 KEY parent (pid),
689 KEY t3ver_oid (t3ver_oid,t3ver_wsid),
690 KEY category_parent (parent),
691 KEY category_list (pid,deleted,sys_language_uid)
692 );
693
694 #
695 # Table structure for table 'sys_category_record_mm'
696 #
697 CREATE TABLE sys_category_record_mm (
698 uid_local int(11) DEFAULT '0' NOT NULL,
699 uid_foreign int(11) DEFAULT '0' NOT NULL,
700 tablenames varchar(255) DEFAULT '' NOT NULL,
701 fieldname varchar(255) DEFAULT '' NOT NULL,
702 sorting int(11) DEFAULT '0' NOT NULL,
703 sorting_foreign int(11) DEFAULT '0' NOT NULL,
704
705 KEY uid_local_foreign (uid_local,uid_foreign),
706 KEY uid_foreign_tablenames (uid_foreign,tablenames)
707 );