9dd81e8f96de79aa528d4928f752c811f9b08717
[Packages/TYPO3.CMS.git] / t3lib / stddb / 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 varchar(255) DEFAULT '' NOT NULL,
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 varchar(255) DEFAULT '' NOT NULL,
23 fileoper_perms tinyint(4) DEFAULT '0' NOT NULL,
24 hidden tinyint(1) unsigned DEFAULT '0' NOT NULL,
25 inc_access_lists tinyint(3) unsigned DEFAULT '0' NOT NULL,
26 description text,
27 lockToDomain varchar(50) DEFAULT '' NOT NULL,
28 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
29 TSconfig text,
30 subgroup varchar(255) DEFAULT '' NOT NULL,
31 hide_in_lists tinyint(4) DEFAULT '0' NOT NULL,
32 workspace_perms tinyint(3) DEFAULT '1' 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(60) 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 varchar(255) DEFAULT '' NOT NULL,
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 varchar(255) DEFAULT '' NOT NULL,
75 allowed_languages varchar(255) DEFAULT '' NOT NULL,
76 uc mediumtext,
77 file_mountpoints varchar(255) DEFAULT '' NOT NULL,
78 fileoper_perms tinyint(4) DEFAULT '0' NOT NULL,
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 varchar(255) DEFAULT '' NOT NULL,
87 workspace_id int(11) DEFAULT '0' NOT NULL,
88 workspace_preview tinyint(3) DEFAULT '1' NOT NULL,
89 PRIMARY KEY (uid),
90 KEY parent (pid),
91 KEY username (username)
92 );
93
94 #
95 # Table structure for table 'cache_imagesizes'
96 #
97 CREATE TABLE cache_imagesizes (
98 md5hash varchar(32) DEFAULT '' NOT NULL,
99 md5filename varchar(32) DEFAULT '' NOT NULL,
100 tstamp int(11) DEFAULT '0' NOT NULL,
101 filename varchar(255) DEFAULT '' NOT NULL,
102 imagewidth mediumint(11) unsigned DEFAULT '0' NOT NULL,
103 imageheight mediumint(11) unsigned DEFAULT '0' NOT NULL,
104 PRIMARY KEY (md5filename)
105 ) ENGINE=InnoDB;
106
107 #
108 # Table structure for table 'pages'
109 #
110 CREATE TABLE pages (
111 uid int(11) NOT NULL auto_increment,
112 pid int(11) DEFAULT '0' NOT NULL,
113 t3ver_oid int(11) DEFAULT '0' NOT NULL,
114 t3ver_id int(11) DEFAULT '0' NOT NULL,
115 t3ver_wsid int(11) DEFAULT '0' NOT NULL,
116 t3ver_label varchar(255) DEFAULT '' NOT NULL,
117 t3ver_state tinyint(4) DEFAULT '0' NOT NULL,
118 t3ver_stage int(11) DEFAULT '0' NOT NULL,
119 t3ver_count int(11) DEFAULT '0' NOT NULL,
120 t3ver_tstamp int(11) DEFAULT '0' NOT NULL,
121 t3ver_swapmode tinyint(4) 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 tinyint(3) 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 tinyint(3) 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 newUntil int(10) unsigned DEFAULT '0' NOT NULL,
160 description text,
161 no_search tinyint(3) unsigned DEFAULT '0' NOT NULL,
162 SYS_LASTCHANGED int(10) unsigned DEFAULT '0' NOT NULL,
163 abstract text,
164 module varchar(10) DEFAULT '' NOT NULL,
165 extendToSubpages tinyint(3) unsigned DEFAULT '0' NOT NULL,
166 author varchar(255) DEFAULT '' NOT NULL,
167 author_email varchar(80) DEFAULT '' NOT NULL,
168 nav_title varchar(255) DEFAULT '' NOT NULL,
169 nav_hide tinyint(4) DEFAULT '0' NOT NULL,
170 content_from_pid int(10) unsigned DEFAULT '0' NOT NULL,
171 mount_pid int(10) unsigned DEFAULT '0' NOT NULL,
172 mount_pid_ol tinyint(4) DEFAULT '0' NOT NULL,
173 alias varchar(32) DEFAULT '' NOT NULL,
174 l18n_cfg tinyint(4) DEFAULT '0' NOT NULL,
175 fe_login_mode tinyint(4) DEFAULT '0' NOT NULL,
176 backend_layout int(10) DEFAULT '0' NOT NULL,
177 backend_layout_next_level int(10) DEFAULT '0' NOT NULL,
178 PRIMARY KEY (uid),
179 KEY t3ver_oid (t3ver_oid,t3ver_wsid),
180 KEY parent (pid,deleted,hidden,sorting),
181 KEY alias (alias)
182 );
183
184 #
185 # Table structure for table 'sys_registry'
186 #
187 CREATE TABLE sys_registry (
188 uid int(11) unsigned NOT NULL auto_increment,
189 entry_namespace varchar(128) DEFAULT '' NOT NULL,
190 entry_key varchar(128) DEFAULT '' NOT NULL,
191 entry_value blob,
192 PRIMARY KEY (uid),
193 UNIQUE KEY entry_identifier (entry_namespace,entry_key)
194 );
195
196 #
197 # Table structure for table 'sys_be_shortcuts'
198 #
199 CREATE TABLE sys_be_shortcuts (
200 uid int(11) unsigned NOT NULL auto_increment,
201 userid int(11) unsigned DEFAULT '0' NOT NULL,
202 module_name varchar(255) DEFAULT '' NOT NULL,
203 url text,
204 description varchar(255) DEFAULT '' NOT NULL,
205 sorting int(11) DEFAULT '0' NOT NULL,
206 sc_group tinyint(4) DEFAULT '0' NOT NULL,
207 PRIMARY KEY (uid),
208 KEY event (userid)
209 );
210
211
212 #
213 # Table structure for table 'sys_news'
214 #
215 CREATE TABLE sys_news (
216 uid int(11) unsigned NOT NULL auto_increment,
217 pid int(11) unsigned DEFAULT '0' NOT NULL,
218 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
219 crdate int(11) unsigned DEFAULT '0' NOT NULL,
220 cruser_id int(11) unsigned DEFAULT '0' NOT NULL,
221 deleted tinyint(3) unsigned DEFAULT '0' NOT NULL,
222 hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
223 starttime int(11) unsigned DEFAULT '0' NOT NULL,
224 endtime int(11) unsigned DEFAULT '0' NOT NULL,
225 title varchar(255) DEFAULT '' NOT NULL,
226 content mediumtext,
227
228 PRIMARY KEY (uid),
229 KEY parent (pid)
230 );
231
232
233 #
234 # Table structure for table 'sys_filemounts'
235 #
236 CREATE TABLE sys_filemounts (
237 uid int(11) unsigned NOT NULL auto_increment,
238 pid int(11) unsigned DEFAULT '0' NOT NULL,
239 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
240 title varchar(30) DEFAULT '' NOT NULL,
241 path varchar(120) DEFAULT '' NOT NULL,
242 base tinyint(4) unsigned DEFAULT '0' NOT NULL,
243 hidden tinyint(3) unsigned DEFAULT '0' NOT NULL,
244 deleted tinyint(1) unsigned DEFAULT '0' NOT NULL,
245 sorting int(11) unsigned DEFAULT '0' NOT NULL,
246 PRIMARY KEY (uid),
247 KEY parent (pid)
248 );
249
250 #
251 # Table structure for table 'sys_history'
252 #
253 CREATE TABLE sys_history (
254 uid int(11) unsigned NOT NULL auto_increment,
255 sys_log_uid int(11) DEFAULT '0' NOT NULL,
256 history_data mediumtext,
257 fieldlist text,
258 recuid int(11) DEFAULT '0' NOT NULL,
259 tablename varchar(255) DEFAULT '' NOT NULL,
260 tstamp int(11) DEFAULT '0' NOT NULL,
261 history_files mediumtext,
262 snapshot tinyint(4) DEFAULT '0' NOT NULL,
263 PRIMARY KEY (uid),
264 KEY recordident_1 (tablename,recuid),
265 KEY recordident_2 (tablename,tstamp),
266 KEY sys_log_uid (sys_log_uid)
267 ) ENGINE=InnoDB;
268
269 #
270 # Table structure for table 'sys_lockedrecords'
271 #
272 CREATE TABLE sys_lockedrecords (
273 uid int(11) unsigned NOT NULL auto_increment,
274 userid int(11) unsigned DEFAULT '0' NOT NULL,
275 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
276 record_table varchar(255) DEFAULT '' NOT NULL,
277 record_uid int(11) DEFAULT '0' NOT NULL,
278 record_pid int(11) DEFAULT '0' NOT NULL,
279 username varchar(50) DEFAULT '' NOT NULL,
280 feuserid int(11) unsigned DEFAULT '0' NOT NULL,
281 PRIMARY KEY (uid),
282 KEY event (userid,tstamp)
283 );
284
285 #
286 # Table structure for table 'sys_refindex'
287 #
288 CREATE TABLE sys_refindex (
289 hash varchar(32) DEFAULT '' NOT NULL,
290 tablename varchar(255) DEFAULT '' NOT NULL,
291 recuid int(11) DEFAULT '0' NOT NULL,
292 field varchar(40) DEFAULT '' NOT NULL,
293 flexpointer varchar(255) DEFAULT '' NOT NULL,
294 softref_key varchar(30) DEFAULT '' NOT NULL,
295 softref_id varchar(40) DEFAULT '' NOT NULL,
296 sorting int(11) DEFAULT '0' NOT NULL,
297 deleted tinyint(1) DEFAULT '0' NOT NULL,
298 ref_table varchar(255) DEFAULT '' NOT NULL,
299 ref_uid int(11) DEFAULT '0' NOT NULL,
300 ref_string varchar(200) DEFAULT '' NOT NULL,
301
302 PRIMARY KEY (hash),
303 KEY lookup_rec (tablename,recuid),
304 KEY lookup_uid (ref_table,ref_uid),
305 KEY lookup_string (ref_string)
306 );
307
308 #
309 # Table structure for table 'sys_log'
310 #
311 CREATE TABLE sys_log (
312 uid int(11) unsigned NOT NULL auto_increment,
313 userid int(11) unsigned DEFAULT '0' NOT NULL,
314 action tinyint(4) unsigned DEFAULT '0' NOT NULL,
315 recuid int(11) unsigned DEFAULT '0' NOT NULL,
316 tablename varchar(255) DEFAULT '' NOT NULL,
317 recpid int(11) DEFAULT '0' NOT NULL,
318 error tinyint(4) unsigned DEFAULT '0' NOT NULL,
319 details text NOT NULL,
320 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
321 type tinyint(3) unsigned DEFAULT '0' NOT NULL,
322 details_nr tinyint(3) unsigned DEFAULT '0' NOT NULL,
323 IP varchar(39) DEFAULT '' NOT NULL,
324 log_data varchar(255) DEFAULT '' NOT NULL,
325 event_pid int(11) DEFAULT '-1' NOT NULL,
326 workspace int(11) DEFAULT '0' NOT NULL,
327 NEWid varchar(20) DEFAULT '' NOT NULL,
328 PRIMARY KEY (uid),
329 KEY event (userid,event_pid),
330 KEY recuidIdx (recuid,uid)
331 ) ENGINE=InnoDB;
332
333 #
334 # Table structure for table 'sys_language'
335 #
336 CREATE TABLE sys_language (
337 uid int(11) unsigned NOT NULL auto_increment,
338 pid int(11) unsigned DEFAULT '0' NOT NULL,
339 tstamp int(11) unsigned DEFAULT '0' NOT NULL,
340 hidden tinyint(4) unsigned DEFAULT '0' NOT NULL,
341 title varchar(80) DEFAULT '' NOT NULL,
342 flag varchar(20) DEFAULT '' NOT NULL,
343 static_lang_isocode int(11) unsigned DEFAULT '0' NOT NULL,
344 PRIMARY KEY (uid),
345 KEY parent (pid)
346 );