1 -- ------------------------------------------
2 -- Friendica 3.5-dev (Asparagus)
3 -- DB_UPDATE_VERSION 1193
4 -- ------------------------------------------
10 CREATE TABLE IF NOT EXISTS `addon` (
11 `id` int(11) NOT NULL auto_increment,
12 `name` varchar(255) NOT NULL DEFAULT '',
13 `version` varchar(255) NOT NULL DEFAULT '',
14 `installed` tinyint(1) NOT NULL DEFAULT 0,
15 `hidden` tinyint(1) NOT NULL DEFAULT 0,
16 `timestamp` bigint(20) NOT NULL DEFAULT 0,
17 `plugin_admin` tinyint(1) NOT NULL DEFAULT 0,
19 ) DEFAULT CHARSET=utf8;
24 CREATE TABLE IF NOT EXISTS `attach` (
25 `id` int(11) NOT NULL auto_increment,
26 `uid` int(11) NOT NULL DEFAULT 0,
27 `hash` varchar(64) NOT NULL DEFAULT '',
28 `filename` varchar(255) NOT NULL DEFAULT '',
29 `filetype` varchar(64) NOT NULL DEFAULT '',
30 `filesize` int(11) NOT NULL DEFAULT 0,
31 `data` longblob NOT NULL,
32 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
33 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
34 `allow_cid` mediumtext NOT NULL,
35 `allow_gid` mediumtext NOT NULL,
36 `deny_cid` mediumtext NOT NULL,
37 `deny_gid` mediumtext NOT NULL,
39 ) DEFAULT CHARSET=utf8;
44 CREATE TABLE IF NOT EXISTS `auth_codes` (
45 `id` varchar(40) NOT NULL,
46 `client_id` varchar(20) NOT NULL DEFAULT '',
47 `redirect_uri` varchar(200) NOT NULL DEFAULT '',
48 `expires` int(11) NOT NULL DEFAULT 0,
49 `scope` varchar(250) NOT NULL DEFAULT '',
51 ) DEFAULT CHARSET=utf8;
56 CREATE TABLE IF NOT EXISTS `cache` (
57 `k` varchar(255) NOT NULL,
59 `expire_mode` int(11) NOT NULL DEFAULT 0,
60 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
62 INDEX `updated` (`updated`)
63 ) DEFAULT CHARSET=utf8;
68 CREATE TABLE IF NOT EXISTS `challenge` (
69 `id` int(10) unsigned NOT NULL auto_increment,
70 `challenge` varchar(255) NOT NULL DEFAULT '',
71 `dfrn-id` varchar(255) NOT NULL DEFAULT '',
72 `expire` int(11) NOT NULL DEFAULT 0,
73 `type` varchar(255) NOT NULL DEFAULT '',
74 `last_update` varchar(255) NOT NULL DEFAULT '',
76 ) DEFAULT CHARSET=utf8;
81 CREATE TABLE IF NOT EXISTS `clients` (
82 `client_id` varchar(20) NOT NULL,
83 `pw` varchar(20) NOT NULL DEFAULT '',
84 `redirect_uri` varchar(200) NOT NULL DEFAULT '',
87 `uid` int(11) NOT NULL DEFAULT 0,
88 PRIMARY KEY(`client_id`)
89 ) DEFAULT CHARSET=utf8;
94 CREATE TABLE IF NOT EXISTS `config` (
95 `id` int(10) unsigned NOT NULL auto_increment,
96 `cat` varchar(255) NOT NULL DEFAULT '',
97 `k` varchar(255) NOT NULL DEFAULT '',
100 INDEX `cat_k` (`cat`(30),`k`(30))
101 ) DEFAULT CHARSET=utf8;
106 CREATE TABLE IF NOT EXISTS `contact` (
107 `id` int(11) NOT NULL auto_increment,
108 `uid` int(11) NOT NULL DEFAULT 0,
109 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
110 `self` tinyint(1) NOT NULL DEFAULT 0,
111 `remote_self` tinyint(1) NOT NULL DEFAULT 0,
112 `rel` tinyint(1) NOT NULL DEFAULT 0,
113 `duplex` tinyint(1) NOT NULL DEFAULT 0,
114 `network` varchar(255) NOT NULL DEFAULT '',
115 `name` varchar(255) NOT NULL DEFAULT '',
116 `nick` varchar(255) NOT NULL DEFAULT '',
117 `location` varchar(255) NOT NULL DEFAULT '',
118 `about` text NOT NULL,
119 `keywords` text NOT NULL,
120 `gender` varchar(32) NOT NULL DEFAULT '',
121 `attag` varchar(255) NOT NULL DEFAULT '',
122 `photo` text NOT NULL,
123 `thumb` text NOT NULL,
124 `micro` text NOT NULL,
125 `site-pubkey` text NOT NULL,
126 `issued-id` varchar(255) NOT NULL DEFAULT '',
127 `dfrn-id` varchar(255) NOT NULL DEFAULT '',
128 `url` varchar(255) NOT NULL DEFAULT '',
129 `nurl` varchar(255) NOT NULL DEFAULT '',
130 `addr` varchar(255) NOT NULL DEFAULT '',
131 `alias` varchar(255) NOT NULL DEFAULT '',
132 `pubkey` text NOT NULL,
133 `prvkey` text NOT NULL,
134 `batch` varchar(255) NOT NULL DEFAULT '',
135 `request` text NOT NULL,
136 `notify` text NOT NULL,
137 `poll` text NOT NULL,
138 `confirm` text NOT NULL,
139 `poco` text NOT NULL,
140 `aes_allow` tinyint(1) NOT NULL DEFAULT 0,
141 `ret-aes` tinyint(1) NOT NULL DEFAULT 0,
142 `usehub` tinyint(1) NOT NULL DEFAULT 0,
143 `subhub` tinyint(1) NOT NULL DEFAULT 0,
144 `hub-verify` varchar(255) NOT NULL DEFAULT '',
145 `last-update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
146 `success_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
147 `failure_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
148 `name-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
149 `uri-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
150 `avatar-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
151 `term-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
152 `last-item` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
153 `priority` tinyint(3) NOT NULL DEFAULT 0,
154 `blocked` tinyint(1) NOT NULL DEFAULT 1,
155 `readonly` tinyint(1) NOT NULL DEFAULT 0,
156 `writable` tinyint(1) NOT NULL DEFAULT 0,
157 `forum` tinyint(1) NOT NULL DEFAULT 0,
158 `prv` tinyint(1) NOT NULL DEFAULT 0,
159 `hidden` tinyint(1) NOT NULL DEFAULT 0,
160 `archive` tinyint(1) NOT NULL DEFAULT 0,
161 `pending` tinyint(1) NOT NULL DEFAULT 1,
162 `rating` tinyint(1) NOT NULL DEFAULT 0,
163 `reason` text NOT NULL,
164 `closeness` tinyint(2) NOT NULL DEFAULT 99,
165 `info` mediumtext NOT NULL,
166 `profile-id` int(11) NOT NULL DEFAULT 0,
167 `bdyear` varchar(4) NOT NULL DEFAULT '',
168 `bd` date NOT NULL DEFAULT '0000-00-00',
169 `notify_new_posts` tinyint(1) NOT NULL DEFAULT 0,
170 `fetch_further_information` tinyint(1) NOT NULL DEFAULT 0,
171 `ffi_keyword_blacklist` mediumtext NOT NULL,
174 ) DEFAULT CHARSET=utf8;
179 CREATE TABLE IF NOT EXISTS `conv` (
180 `id` int(10) unsigned NOT NULL auto_increment,
181 `guid` varchar(64) NOT NULL DEFAULT '',
182 `recips` mediumtext NOT NULL,
183 `uid` int(11) NOT NULL DEFAULT 0,
184 `creator` varchar(255) NOT NULL DEFAULT '',
185 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
186 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
187 `subject` mediumtext NOT NULL,
190 ) DEFAULT CHARSET=utf8;
195 CREATE TABLE IF NOT EXISTS `deliverq` (
196 `id` int(10) unsigned NOT NULL auto_increment,
197 `cmd` varchar(32) NOT NULL DEFAULT '',
198 `item` int(11) NOT NULL DEFAULT 0,
199 `contact` int(11) NOT NULL DEFAULT 0,
201 ) DEFAULT CHARSET=utf8;
206 CREATE TABLE IF NOT EXISTS `dsprphotoq` (
207 `id` int(10) unsigned NOT NULL auto_increment,
208 `uid` int(11) NOT NULL DEFAULT 0,
209 `msg` mediumtext NOT NULL,
210 `attempt` tinyint(4) NOT NULL DEFAULT 0,
212 ) DEFAULT CHARSET=utf8;
217 CREATE TABLE IF NOT EXISTS `event` (
218 `id` int(11) NOT NULL auto_increment,
219 `uid` int(11) NOT NULL DEFAULT 0,
220 `cid` int(11) NOT NULL DEFAULT 0,
221 `uri` varchar(255) NOT NULL DEFAULT '',
222 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
223 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
224 `start` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
225 `finish` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
226 `summary` text NOT NULL,
227 `desc` text NOT NULL,
228 `location` text NOT NULL,
229 `type` varchar(255) NOT NULL DEFAULT '',
230 `nofinish` tinyint(1) NOT NULL DEFAULT 0,
231 `adjust` tinyint(1) NOT NULL DEFAULT 1,
232 `ignore` tinyint(1) unsigned NOT NULL DEFAULT 0,
233 `allow_cid` mediumtext NOT NULL,
234 `allow_gid` mediumtext NOT NULL,
235 `deny_cid` mediumtext NOT NULL,
236 `deny_gid` mediumtext NOT NULL,
239 ) DEFAULT CHARSET=utf8;
244 CREATE TABLE IF NOT EXISTS `fcontact` (
245 `id` int(10) unsigned NOT NULL auto_increment,
246 `url` varchar(255) NOT NULL DEFAULT '',
247 `name` varchar(255) NOT NULL DEFAULT '',
248 `photo` varchar(255) NOT NULL DEFAULT '',
249 `request` varchar(255) NOT NULL DEFAULT '',
250 `nick` varchar(255) NOT NULL DEFAULT '',
251 `addr` varchar(255) NOT NULL DEFAULT '',
252 `batch` varchar(255) NOT NULL DEFAULT '',
253 `notify` varchar(255) NOT NULL DEFAULT '',
254 `poll` varchar(255) NOT NULL DEFAULT '',
255 `confirm` varchar(255) NOT NULL DEFAULT '',
256 `priority` tinyint(1) NOT NULL DEFAULT 0,
257 `network` varchar(32) NOT NULL DEFAULT '',
258 `alias` varchar(255) NOT NULL DEFAULT '',
259 `pubkey` text NOT NULL,
260 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
262 INDEX `addr` (`addr`)
263 ) DEFAULT CHARSET=utf8;
268 CREATE TABLE IF NOT EXISTS `ffinder` (
269 `id` int(10) unsigned NOT NULL auto_increment,
270 `uid` int(10) unsigned NOT NULL DEFAULT 0,
271 `cid` int(10) unsigned NOT NULL DEFAULT 0,
272 `fid` int(10) unsigned NOT NULL DEFAULT 0,
274 ) DEFAULT CHARSET=utf8;
279 CREATE TABLE IF NOT EXISTS `fserver` (
280 `id` int(11) NOT NULL auto_increment,
281 `server` varchar(255) NOT NULL DEFAULT '',
282 `posturl` varchar(255) NOT NULL DEFAULT '',
285 INDEX `server` (`server`)
286 ) DEFAULT CHARSET=utf8;
291 CREATE TABLE IF NOT EXISTS `fsuggest` (
292 `id` int(11) NOT NULL auto_increment,
293 `uid` int(11) NOT NULL DEFAULT 0,
294 `cid` int(11) NOT NULL DEFAULT 0,
295 `name` varchar(255) NOT NULL DEFAULT '',
296 `url` varchar(255) NOT NULL DEFAULT '',
297 `request` varchar(255) NOT NULL DEFAULT '',
298 `photo` varchar(255) NOT NULL DEFAULT '',
299 `note` text NOT NULL,
300 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
302 ) DEFAULT CHARSET=utf8;
307 CREATE TABLE IF NOT EXISTS `gcign` (
308 `id` int(11) NOT NULL auto_increment,
309 `uid` int(11) NOT NULL DEFAULT 0,
310 `gcid` int(11) NOT NULL DEFAULT 0,
313 INDEX `gcid` (`gcid`)
314 ) DEFAULT CHARSET=utf8;
319 CREATE TABLE IF NOT EXISTS `gcontact` (
320 `id` int(10) unsigned NOT NULL auto_increment,
321 `name` varchar(255) NOT NULL DEFAULT '',
322 `nick` varchar(255) NOT NULL DEFAULT '',
323 `url` varchar(255) NOT NULL DEFAULT '',
324 `nurl` varchar(255) NOT NULL DEFAULT '',
325 `photo` varchar(255) NOT NULL DEFAULT '',
326 `connect` varchar(255) NOT NULL DEFAULT '',
327 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
328 `updated` datetime DEFAULT '0000-00-00 00:00:00',
329 `last_contact` datetime DEFAULT '0000-00-00 00:00:00',
330 `last_failure` datetime DEFAULT '0000-00-00 00:00:00',
331 `location` varchar(255) NOT NULL DEFAULT '',
332 `about` text NOT NULL,
333 `keywords` text NOT NULL,
334 `gender` varchar(32) NOT NULL DEFAULT '',
335 `birthday` varchar(32) NOT NULL DEFAULT '0000-00-00',
336 `community` tinyint(1) NOT NULL DEFAULT 0,
337 `hide` tinyint(1) NOT NULL DEFAULT 0,
338 `nsfw` tinyint(1) NOT NULL DEFAULT 0,
339 `network` varchar(255) NOT NULL DEFAULT '',
340 `addr` varchar(255) NOT NULL DEFAULT '',
341 `notify` text NOT NULL,
342 `alias` varchar(255) NOT NULL DEFAULT '',
343 `generation` tinyint(3) NOT NULL DEFAULT 0,
344 `server_url` varchar(255) NOT NULL DEFAULT '',
346 INDEX `nurl` (`nurl`),
347 INDEX `updated` (`updated`)
348 ) DEFAULT CHARSET=utf8;
353 CREATE TABLE IF NOT EXISTS `glink` (
354 `id` int(10) unsigned NOT NULL auto_increment,
355 `cid` int(11) NOT NULL DEFAULT 0,
356 `uid` int(11) NOT NULL DEFAULT 0,
357 `gcid` int(11) NOT NULL DEFAULT 0,
358 `zcid` int(11) NOT NULL DEFAULT 0,
359 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
361 INDEX `cid_uid_gcid_zcid` (`cid`,`uid`,`gcid`,`zcid`),
362 INDEX `gcid` (`gcid`),
363 INDEX `zcid` (`zcid`)
364 ) DEFAULT CHARSET=utf8;
369 CREATE TABLE IF NOT EXISTS `group` (
370 `id` int(10) unsigned NOT NULL auto_increment,
371 `uid` int(10) unsigned NOT NULL DEFAULT 0,
372 `visible` tinyint(1) NOT NULL DEFAULT 0,
373 `deleted` tinyint(1) NOT NULL DEFAULT 0,
374 `name` varchar(255) NOT NULL DEFAULT '',
377 ) DEFAULT CHARSET=utf8;
380 -- TABLE group_member
382 CREATE TABLE IF NOT EXISTS `group_member` (
383 `id` int(10) unsigned NOT NULL auto_increment,
384 `uid` int(10) unsigned NOT NULL DEFAULT 0,
385 `gid` int(10) unsigned NOT NULL DEFAULT 0,
386 `contact-id` int(10) unsigned NOT NULL DEFAULT 0,
388 INDEX `uid_gid_contactid` (`uid`,`gid`,`contact-id`)
389 ) DEFAULT CHARSET=utf8;
394 CREATE TABLE IF NOT EXISTS `gserver` (
395 `id` int(10) unsigned NOT NULL auto_increment,
396 `url` varchar(255) NOT NULL DEFAULT '',
397 `nurl` varchar(255) NOT NULL DEFAULT '',
398 `version` varchar(255) NOT NULL DEFAULT '',
399 `site_name` varchar(255) NOT NULL DEFAULT '',
400 `info` text NOT NULL,
401 `register_policy` tinyint(1) NOT NULL DEFAULT 0,
402 `poco` varchar(255) NOT NULL DEFAULT '',
403 `noscrape` varchar(255) NOT NULL DEFAULT '',
404 `network` varchar(32) NOT NULL DEFAULT '',
405 `platform` varchar(255) NOT NULL DEFAULT '',
406 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
407 `last_poco_query` datetime DEFAULT '0000-00-00 00:00:00',
408 `last_contact` datetime DEFAULT '0000-00-00 00:00:00',
409 `last_failure` datetime DEFAULT '0000-00-00 00:00:00',
411 INDEX `nurl` (`nurl`)
412 ) DEFAULT CHARSET=utf8;
417 CREATE TABLE IF NOT EXISTS `guid` (
418 `id` int(10) unsigned NOT NULL auto_increment,
419 `guid` varchar(255) NOT NULL DEFAULT '',
420 `plink` varchar(255) NOT NULL DEFAULT '',
421 `uri` varchar(255) NOT NULL DEFAULT '',
422 `network` varchar(32) NOT NULL DEFAULT '',
424 INDEX `guid` (`guid`),
425 INDEX `plink` (`plink`),
427 ) DEFAULT CHARSET=utf8;
432 CREATE TABLE IF NOT EXISTS `hook` (
433 `id` int(11) NOT NULL auto_increment,
434 `hook` varchar(255) NOT NULL DEFAULT '',
435 `file` varchar(255) NOT NULL DEFAULT '',
436 `function` varchar(255) NOT NULL DEFAULT '',
437 `priority` int(11) unsigned NOT NULL DEFAULT 0,
439 INDEX `hook_file_function` (`hook`(30),`file`(60),`function`(30))
440 ) DEFAULT CHARSET=utf8;
445 CREATE TABLE IF NOT EXISTS `intro` (
446 `id` int(10) unsigned NOT NULL auto_increment,
447 `uid` int(10) unsigned NOT NULL DEFAULT 0,
448 `fid` int(11) NOT NULL DEFAULT 0,
449 `contact-id` int(11) NOT NULL DEFAULT 0,
450 `knowyou` tinyint(1) NOT NULL DEFAULT 0,
451 `duplex` tinyint(1) NOT NULL DEFAULT 0,
452 `note` text NOT NULL,
453 `hash` varchar(255) NOT NULL DEFAULT '',
454 `datetime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
455 `blocked` tinyint(1) NOT NULL DEFAULT 1,
456 `ignore` tinyint(1) NOT NULL DEFAULT 0,
458 ) DEFAULT CHARSET=utf8;
463 CREATE TABLE IF NOT EXISTS `item` (
464 `id` int(10) unsigned NOT NULL auto_increment,
465 `guid` varchar(255) NOT NULL DEFAULT '',
466 `uri` varchar(255) NOT NULL DEFAULT '',
467 `uid` int(10) unsigned NOT NULL DEFAULT 0,
468 `contact-id` int(11) NOT NULL DEFAULT 0,
469 `gcontact-id` int(11) unsigned NOT NULL DEFAULT 0,
470 `type` varchar(255) NOT NULL DEFAULT '',
471 `wall` tinyint(1) NOT NULL DEFAULT 0,
472 `gravity` tinyint(1) NOT NULL DEFAULT 0,
473 `parent` int(10) unsigned NOT NULL DEFAULT 0,
474 `parent-uri` varchar(255) NOT NULL DEFAULT '',
475 `extid` varchar(255) NOT NULL DEFAULT '',
476 `thr-parent` varchar(255) NOT NULL DEFAULT '',
477 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
478 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
479 `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
480 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
481 `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
482 `owner-name` varchar(255) NOT NULL DEFAULT '',
483 `owner-link` varchar(255) NOT NULL DEFAULT '',
484 `owner-avatar` varchar(255) NOT NULL DEFAULT '',
485 `author-name` varchar(255) NOT NULL DEFAULT '',
486 `author-link` varchar(255) NOT NULL DEFAULT '',
487 `author-avatar` varchar(255) NOT NULL DEFAULT '',
488 `title` varchar(255) NOT NULL DEFAULT '',
489 `body` mediumtext NOT NULL,
490 `app` varchar(255) NOT NULL DEFAULT '',
491 `verb` varchar(255) NOT NULL DEFAULT '',
492 `object-type` varchar(255) NOT NULL DEFAULT '',
493 `object` text NOT NULL,
494 `target-type` varchar(255) NOT NULL DEFAULT '',
495 `target` text NOT NULL,
496 `postopts` text NOT NULL,
497 `plink` varchar(255) NOT NULL DEFAULT '',
498 `resource-id` varchar(255) NOT NULL DEFAULT '',
499 `event-id` int(11) NOT NULL DEFAULT 0,
500 `tag` mediumtext NOT NULL,
501 `attach` mediumtext NOT NULL,
502 `inform` mediumtext NOT NULL,
503 `file` mediumtext NOT NULL,
504 `location` varchar(255) NOT NULL DEFAULT '',
505 `coord` varchar(255) NOT NULL DEFAULT '',
506 `allow_cid` mediumtext NOT NULL,
507 `allow_gid` mediumtext NOT NULL,
508 `deny_cid` mediumtext NOT NULL,
509 `deny_gid` mediumtext NOT NULL,
510 `private` tinyint(1) NOT NULL DEFAULT 0,
511 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
512 `moderated` tinyint(1) NOT NULL DEFAULT 0,
513 `visible` tinyint(1) NOT NULL DEFAULT 0,
514 `spam` tinyint(1) NOT NULL DEFAULT 0,
515 `starred` tinyint(1) NOT NULL DEFAULT 0,
516 `bookmark` tinyint(1) NOT NULL DEFAULT 0,
517 `unseen` tinyint(1) NOT NULL DEFAULT 1,
518 `deleted` tinyint(1) NOT NULL DEFAULT 0,
519 `origin` tinyint(1) NOT NULL DEFAULT 0,
520 `forum_mode` tinyint(1) NOT NULL DEFAULT 0,
521 `last-child` tinyint(1) unsigned NOT NULL DEFAULT 1,
522 `mention` tinyint(1) NOT NULL DEFAULT 0,
523 `network` varchar(32) NOT NULL DEFAULT '',
524 `rendered-hash` varchar(32) NOT NULL DEFAULT '',
525 `rendered-html` mediumtext NOT NULL,
526 `global` tinyint(1) NOT NULL DEFAULT 0,
528 INDEX `guid` (`guid`),
530 INDEX `parent` (`parent`),
531 INDEX `parent-uri` (`parent-uri`),
532 INDEX `extid` (`extid`),
533 INDEX `uid_id` (`uid`,`id`),
534 INDEX `uid_created` (`uid`,`created`),
535 INDEX `uid_unseen` (`uid`,`unseen`),
536 INDEX `uid_network_received` (`uid`,`network`,`received`),
537 INDEX `uid_received` (`uid`,`received`),
538 INDEX `uid_network_commented` (`uid`,`network`,`commented`),
539 INDEX `uid_commented` (`uid`,`commented`),
540 INDEX `uid_title` (`uid`,`title`),
541 INDEX `uid_thrparent` (`uid`,`thr-parent`),
542 INDEX `uid_parenturi` (`uid`,`parent-uri`),
543 INDEX `uid_contactid_created` (`uid`,`contact-id`,`created`),
544 INDEX `gcontactid_uid_created` (`gcontact-id`,`uid`,`created`),
545 INDEX `wall_body` (`wall`,`body`(6)),
546 INDEX `uid_visible_moderated_created` (`uid`,`visible`,`moderated`,`created`),
547 INDEX `uid_uri` (`uid`,`uri`),
548 INDEX `uid_wall_created` (`uid`,`wall`,`created`),
549 INDEX `resource-id` (`resource-id`),
550 INDEX `uid_type` (`uid`,`type`),
551 INDEX `uid_starred` (`uid`,`starred`),
552 INDEX `contactid_allowcid_allowpid_denycid_denygid` (`contact-id`,`allow_cid`(10),`allow_gid`(10),`deny_cid`(10),`deny_gid`(10)),
553 INDEX `uid_wall_parent_created` (`uid`,`wall`,`parent`,`created`),
554 INDEX `uid_type_changed` (`uid`,`type`,`changed`),
555 INDEX `contactid_verb` (`contact-id`,`verb`),
556 INDEX `deleted_changed` (`deleted`,`changed`),
557 INDEX `uid_wall_changed` (`uid`,`wall`,`changed`),
558 INDEX `uid_eventid` (`uid`,`event-id`),
559 INDEX `uid_authorlink` (`uid`,`author-link`),
560 INDEX `uid_ownerlink` (`uid`,`owner-link`)
561 ) DEFAULT CHARSET=utf8;
566 CREATE TABLE IF NOT EXISTS `item_id` (
567 `id` int(11) NOT NULL auto_increment,
568 `iid` int(11) NOT NULL DEFAULT 0,
569 `uid` int(11) NOT NULL DEFAULT 0,
570 `sid` varchar(255) NOT NULL DEFAULT '',
571 `service` varchar(255) NOT NULL DEFAULT '',
575 INDEX `service` (`service`),
577 ) DEFAULT CHARSET=utf8;
582 CREATE TABLE IF NOT EXISTS `locks` (
583 `id` int(11) NOT NULL auto_increment,
584 `name` varchar(128) NOT NULL DEFAULT '',
585 `locked` tinyint(1) NOT NULL DEFAULT 0,
586 `created` datetime DEFAULT '0000-00-00 00:00:00',
588 ) DEFAULT CHARSET=utf8;
593 CREATE TABLE IF NOT EXISTS `mail` (
594 `id` int(10) unsigned NOT NULL auto_increment,
595 `uid` int(10) unsigned NOT NULL DEFAULT 0,
596 `guid` varchar(64) NOT NULL DEFAULT '',
597 `from-name` varchar(255) NOT NULL DEFAULT '',
598 `from-photo` varchar(255) NOT NULL DEFAULT '',
599 `from-url` varchar(255) NOT NULL DEFAULT '',
600 `contact-id` varchar(255) NOT NULL DEFAULT '',
601 `convid` int(11) unsigned NOT NULL DEFAULT 0,
602 `title` varchar(255) NOT NULL DEFAULT '',
603 `body` mediumtext NOT NULL,
604 `seen` tinyint(1) NOT NULL DEFAULT 0,
605 `reply` tinyint(1) NOT NULL DEFAULT 0,
606 `replied` tinyint(1) NOT NULL DEFAULT 0,
607 `unknown` tinyint(1) NOT NULL DEFAULT 0,
608 `uri` varchar(255) NOT NULL DEFAULT '',
609 `parent-uri` varchar(255) NOT NULL DEFAULT '',
610 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
613 INDEX `guid` (`guid`),
614 INDEX `convid` (`convid`),
615 INDEX `reply` (`reply`),
617 INDEX `parent-uri` (`parent-uri`)
618 ) DEFAULT CHARSET=utf8;
623 CREATE TABLE IF NOT EXISTS `mailacct` (
624 `id` int(11) NOT NULL auto_increment,
625 `uid` int(11) NOT NULL DEFAULT 0,
626 `server` varchar(255) NOT NULL DEFAULT '',
627 `port` int(11) NOT NULL DEFAULT 0,
628 `ssltype` varchar(16) NOT NULL DEFAULT '',
629 `mailbox` varchar(255) NOT NULL DEFAULT '',
630 `user` varchar(255) NOT NULL DEFAULT '',
631 `pass` text NOT NULL,
632 `reply_to` varchar(255) NOT NULL DEFAULT '',
633 `action` int(11) NOT NULL DEFAULT 0,
634 `movetofolder` varchar(255) NOT NULL DEFAULT '',
635 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
636 `last_check` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
638 ) DEFAULT CHARSET=utf8;
643 CREATE TABLE IF NOT EXISTS `manage` (
644 `id` int(11) NOT NULL auto_increment,
645 `uid` int(11) NOT NULL DEFAULT 0,
646 `mid` int(11) NOT NULL DEFAULT 0,
648 INDEX `uid_mid` (`uid`,`mid`)
649 ) DEFAULT CHARSET=utf8;
654 CREATE TABLE IF NOT EXISTS `notify` (
655 `id` int(11) NOT NULL auto_increment,
656 `hash` varchar(64) NOT NULL DEFAULT '',
657 `type` int(11) NOT NULL DEFAULT 0,
658 `name` varchar(255) NOT NULL DEFAULT '',
659 `url` varchar(255) NOT NULL DEFAULT '',
660 `photo` varchar(255) NOT NULL DEFAULT '',
661 `date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
662 `msg` mediumtext NOT NULL,
663 `uid` int(11) NOT NULL DEFAULT 0,
664 `link` varchar(255) NOT NULL DEFAULT '',
665 `iid` int(11) NOT NULL DEFAULT 0,
666 `parent` int(11) NOT NULL DEFAULT 0,
667 `seen` tinyint(1) NOT NULL DEFAULT 0,
668 `verb` varchar(255) NOT NULL DEFAULT '',
669 `otype` varchar(16) NOT NULL DEFAULT '',
672 ) DEFAULT CHARSET=utf8;
675 -- TABLE notify-threads
677 CREATE TABLE IF NOT EXISTS `notify-threads` (
678 `id` int(11) NOT NULL auto_increment,
679 `notify-id` int(11) NOT NULL DEFAULT 0,
680 `master-parent-item` int(10) unsigned NOT NULL DEFAULT 0,
681 `parent-item` int(10) unsigned NOT NULL DEFAULT 0,
682 `receiver-uid` int(11) NOT NULL DEFAULT 0,
684 INDEX `master-parent-item` (`master-parent-item`),
685 INDEX `receiver-uid` (`receiver-uid`)
686 ) DEFAULT CHARSET=utf8;
691 CREATE TABLE IF NOT EXISTS `oembed` (
692 `url` varchar(255) NOT NULL,
693 `content` text NOT NULL,
694 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
696 INDEX `created` (`created`)
697 ) DEFAULT CHARSET=utf8;
702 CREATE TABLE IF NOT EXISTS `parsed_url` (
703 `url` varchar(255) NOT NULL,
704 `guessing` tinyint(1) NOT NULL DEFAULT 0,
705 `oembed` tinyint(1) NOT NULL DEFAULT 0,
706 `content` text NOT NULL,
707 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
708 PRIMARY KEY(`url`,`guessing`,`oembed`),
709 INDEX `created` (`created`)
710 ) DEFAULT CHARSET=utf8;
715 CREATE TABLE IF NOT EXISTS `pconfig` (
716 `id` int(11) NOT NULL auto_increment,
717 `uid` int(11) NOT NULL DEFAULT 0,
718 `cat` varchar(255) NOT NULL DEFAULT '',
719 `k` varchar(255) NOT NULL DEFAULT '',
720 `v` mediumtext NOT NULL,
722 INDEX `uid_cat_k` (`uid`,`cat`(30),`k`(30))
723 ) DEFAULT CHARSET=utf8;
728 CREATE TABLE IF NOT EXISTS `photo` (
729 `id` int(10) unsigned NOT NULL auto_increment,
730 `uid` int(10) unsigned NOT NULL DEFAULT 0,
731 `contact-id` int(10) unsigned NOT NULL DEFAULT 0,
732 `guid` varchar(64) NOT NULL DEFAULT '',
733 `resource-id` varchar(255) NOT NULL DEFAULT '',
734 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
735 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
736 `title` varchar(255) NOT NULL DEFAULT '',
737 `desc` text NOT NULL,
738 `album` varchar(255) NOT NULL DEFAULT '',
739 `filename` varchar(255) NOT NULL DEFAULT '',
740 `type` varchar(128) NOT NULL DEFAULT 'image/jpeg',
741 `height` smallint(6) NOT NULL DEFAULT 0,
742 `width` smallint(6) NOT NULL DEFAULT 0,
743 `datasize` int(10) unsigned NOT NULL DEFAULT 0,
744 `data` mediumblob NOT NULL,
745 `scale` tinyint(3) NOT NULL DEFAULT 0,
746 `profile` tinyint(1) NOT NULL DEFAULT 0,
747 `allow_cid` mediumtext NOT NULL,
748 `allow_gid` mediumtext NOT NULL,
749 `deny_cid` mediumtext NOT NULL,
750 `deny_gid` mediumtext NOT NULL,
753 INDEX `resource-id` (`resource-id`),
754 INDEX `guid` (`guid`)
755 ) DEFAULT CHARSET=utf8;
760 CREATE TABLE IF NOT EXISTS `poll` (
761 `id` int(11) NOT NULL auto_increment,
762 `uid` int(11) NOT NULL DEFAULT 0,
763 `q0` mediumtext NOT NULL,
764 `q1` mediumtext NOT NULL,
765 `q2` mediumtext NOT NULL,
766 `q3` mediumtext NOT NULL,
767 `q4` mediumtext NOT NULL,
768 `q5` mediumtext NOT NULL,
769 `q6` mediumtext NOT NULL,
770 `q7` mediumtext NOT NULL,
771 `q8` mediumtext NOT NULL,
772 `q9` mediumtext NOT NULL,
775 ) DEFAULT CHARSET=utf8;
780 CREATE TABLE IF NOT EXISTS `poll_result` (
781 `id` int(11) NOT NULL auto_increment,
782 `poll_id` int(11) NOT NULL DEFAULT 0,
783 `choice` int(11) NOT NULL DEFAULT 0,
785 INDEX `poll_id` (`poll_id`),
786 INDEX `choice` (`choice`)
787 ) DEFAULT CHARSET=utf8;
792 CREATE TABLE IF NOT EXISTS `profile` (
793 `id` int(11) NOT NULL auto_increment,
794 `uid` int(11) NOT NULL DEFAULT 0,
795 `profile-name` varchar(255) NOT NULL DEFAULT '',
796 `is-default` tinyint(1) NOT NULL DEFAULT 0,
797 `hide-friends` tinyint(1) NOT NULL DEFAULT 0,
798 `name` varchar(255) NOT NULL DEFAULT '',
799 `pdesc` varchar(255) NOT NULL DEFAULT '',
800 `dob` varchar(32) NOT NULL DEFAULT '0000-00-00',
801 `address` varchar(255) NOT NULL DEFAULT '',
802 `locality` varchar(255) NOT NULL DEFAULT '',
803 `region` varchar(255) NOT NULL DEFAULT '',
804 `postal-code` varchar(32) NOT NULL DEFAULT '',
805 `country-name` varchar(255) NOT NULL DEFAULT '',
806 `hometown` varchar(255) NOT NULL DEFAULT '',
807 `gender` varchar(32) NOT NULL DEFAULT '',
808 `marital` varchar(255) NOT NULL DEFAULT '',
809 `with` text NOT NULL,
810 `howlong` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
811 `sexual` varchar(255) NOT NULL DEFAULT '',
812 `politic` varchar(255) NOT NULL DEFAULT '',
813 `religion` varchar(255) NOT NULL DEFAULT '',
814 `pub_keywords` text NOT NULL,
815 `prv_keywords` text NOT NULL,
816 `likes` text NOT NULL,
817 `dislikes` text NOT NULL,
818 `about` text NOT NULL,
819 `summary` varchar(255) NOT NULL DEFAULT '',
820 `music` text NOT NULL,
821 `book` text NOT NULL,
823 `film` text NOT NULL,
824 `interest` text NOT NULL,
825 `romance` text NOT NULL,
826 `work` text NOT NULL,
827 `education` text NOT NULL,
828 `contact` text NOT NULL,
829 `homepage` varchar(255) NOT NULL DEFAULT '',
830 `photo` varchar(255) NOT NULL DEFAULT '',
831 `thumb` varchar(255) NOT NULL DEFAULT '',
832 `publish` tinyint(1) NOT NULL DEFAULT 0,
833 `net-publish` tinyint(1) NOT NULL DEFAULT 0,
835 INDEX `hometown` (`hometown`)
836 ) DEFAULT CHARSET=utf8;
839 -- TABLE profile_check
841 CREATE TABLE IF NOT EXISTS `profile_check` (
842 `id` int(10) unsigned NOT NULL auto_increment,
843 `uid` int(10) unsigned NOT NULL DEFAULT 0,
844 `cid` int(10) unsigned NOT NULL DEFAULT 0,
845 `dfrn_id` varchar(255) NOT NULL DEFAULT '',
846 `sec` varchar(255) NOT NULL DEFAULT '',
847 `expire` int(11) NOT NULL DEFAULT 0,
849 ) DEFAULT CHARSET=utf8;
852 -- TABLE push_subscriber
854 CREATE TABLE IF NOT EXISTS `push_subscriber` (
855 `id` int(11) NOT NULL auto_increment,
856 `uid` int(11) NOT NULL DEFAULT 0,
857 `callback_url` varchar(255) NOT NULL DEFAULT '',
858 `topic` varchar(255) NOT NULL DEFAULT '',
859 `nickname` varchar(255) NOT NULL DEFAULT '',
860 `push` int(11) NOT NULL DEFAULT 0,
861 `last_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
862 `secret` varchar(255) NOT NULL DEFAULT '',
864 ) DEFAULT CHARSET=utf8;
869 CREATE TABLE IF NOT EXISTS `queue` (
870 `id` int(11) NOT NULL auto_increment,
871 `cid` int(11) NOT NULL DEFAULT 0,
872 `network` varchar(32) NOT NULL DEFAULT '',
873 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
874 `last` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
875 `content` mediumtext NOT NULL,
876 `batch` tinyint(1) NOT NULL DEFAULT 0,
879 INDEX `created` (`created`),
880 INDEX `last` (`last`),
881 INDEX `network` (`network`),
882 INDEX `batch` (`batch`)
883 ) DEFAULT CHARSET=utf8;
888 CREATE TABLE IF NOT EXISTS `register` (
889 `id` int(11) unsigned NOT NULL auto_increment,
890 `hash` varchar(255) NOT NULL DEFAULT '',
891 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
892 `uid` int(11) unsigned NOT NULL DEFAULT 0,
893 `password` varchar(255) NOT NULL DEFAULT '',
894 `language` varchar(16) NOT NULL DEFAULT '',
896 ) DEFAULT CHARSET=utf8;
901 CREATE TABLE IF NOT EXISTS `search` (
902 `id` int(11) NOT NULL auto_increment,
903 `uid` int(11) NOT NULL DEFAULT 0,
904 `term` varchar(255) NOT NULL DEFAULT '',
907 INDEX `term` (`term`)
908 ) DEFAULT CHARSET=utf8;
913 CREATE TABLE IF NOT EXISTS `session` (
914 `id` bigint(20) unsigned NOT NULL auto_increment,
915 `sid` varchar(255) NOT NULL DEFAULT '',
916 `data` text NOT NULL,
917 `expire` int(10) unsigned NOT NULL DEFAULT 0,
920 INDEX `expire` (`expire`)
921 ) DEFAULT CHARSET=utf8;
926 CREATE TABLE IF NOT EXISTS `sign` (
927 `id` int(10) unsigned NOT NULL auto_increment,
928 `iid` int(10) unsigned NOT NULL DEFAULT 0,
929 `retract_iid` int(10) unsigned NOT NULL DEFAULT 0,
930 `signed_text` mediumtext NOT NULL,
931 `signature` text NOT NULL,
932 `signer` varchar(255) NOT NULL DEFAULT '',
935 INDEX `retract_iid` (`retract_iid`)
936 ) DEFAULT CHARSET=utf8;
941 CREATE TABLE IF NOT EXISTS `spam` (
942 `id` int(11) NOT NULL auto_increment,
943 `uid` int(11) NOT NULL DEFAULT 0,
944 `spam` int(11) NOT NULL DEFAULT 0,
945 `ham` int(11) NOT NULL DEFAULT 0,
946 `term` varchar(255) NOT NULL DEFAULT '',
947 `date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
950 INDEX `spam` (`spam`),
952 INDEX `term` (`term`)
953 ) DEFAULT CHARSET=utf8;
958 CREATE TABLE IF NOT EXISTS `term` (
959 `tid` int(10) unsigned NOT NULL auto_increment,
960 `oid` int(10) unsigned NOT NULL DEFAULT 0,
961 `otype` tinyint(3) unsigned NOT NULL DEFAULT 0,
962 `type` tinyint(3) unsigned NOT NULL DEFAULT 0,
963 `term` varchar(255) NOT NULL DEFAULT '',
964 `url` varchar(255) NOT NULL DEFAULT '',
965 `guid` varchar(255) NOT NULL DEFAULT '',
966 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
967 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
968 `global` tinyint(1) NOT NULL DEFAULT 0,
969 `aid` int(10) unsigned NOT NULL DEFAULT 0,
970 `uid` int(10) unsigned NOT NULL DEFAULT 0,
972 INDEX `oid_otype_type_term` (`oid`,`otype`,`type`,`term`),
973 INDEX `uid_term_tid` (`uid`,`term`,`tid`),
974 INDEX `type_term` (`type`,`term`),
975 INDEX `uid_otype_type_term_global_created` (`uid`,`otype`,`type`,`term`,`global`,`created`),
976 INDEX `otype_type_term_tid` (`otype`,`type`,`term`,`tid`),
977 INDEX `guid` (`guid`)
978 ) DEFAULT CHARSET=utf8;
983 CREATE TABLE IF NOT EXISTS `thread` (
984 `iid` int(10) unsigned NOT NULL DEFAULT 0,
985 `uid` int(10) unsigned NOT NULL DEFAULT 0,
986 `contact-id` int(11) unsigned NOT NULL DEFAULT 0,
987 `gcontact-id` int(11) unsigned NOT NULL DEFAULT 0,
988 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
989 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
990 `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
991 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
992 `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
993 `wall` tinyint(1) NOT NULL DEFAULT 0,
994 `private` tinyint(1) NOT NULL DEFAULT 0,
995 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
996 `moderated` tinyint(1) NOT NULL DEFAULT 0,
997 `visible` tinyint(1) NOT NULL DEFAULT 0,
998 `spam` tinyint(1) NOT NULL DEFAULT 0,
999 `starred` tinyint(1) NOT NULL DEFAULT 0,
1000 `ignored` tinyint(1) NOT NULL DEFAULT 0,
1001 `bookmark` tinyint(1) NOT NULL DEFAULT 0,
1002 `unseen` tinyint(1) NOT NULL DEFAULT 1,
1003 `deleted` tinyint(1) NOT NULL DEFAULT 0,
1004 `origin` tinyint(1) NOT NULL DEFAULT 0,
1005 `forum_mode` tinyint(1) NOT NULL DEFAULT 0,
1006 `mention` tinyint(1) NOT NULL DEFAULT 0,
1007 `network` varchar(32) NOT NULL DEFAULT '',
1009 INDEX `created` (`created`),
1010 INDEX `commented` (`commented`),
1011 INDEX `uid_network_commented` (`uid`,`network`,`commented`),
1012 INDEX `uid_network_created` (`uid`,`network`,`created`),
1013 INDEX `uid_contactid_commented` (`uid`,`contact-id`,`commented`),
1014 INDEX `uid_contactid_created` (`uid`,`contact-id`,`created`),
1015 INDEX `uid_gcontactid_commented` (`uid`,`gcontact-id`,`commented`),
1016 INDEX `uid_gcontactid_created` (`uid`,`gcontact-id`,`created`),
1017 INDEX `wall_private_received` (`wall`,`private`,`received`),
1018 INDEX `uid_created` (`uid`,`created`),
1019 INDEX `uid_commented` (`uid`,`commented`)
1020 ) DEFAULT CHARSET=utf8;
1025 CREATE TABLE IF NOT EXISTS `tokens` (
1026 `id` varchar(40) NOT NULL,
1027 `secret` text NOT NULL,
1028 `client_id` varchar(20) NOT NULL DEFAULT '',
1029 `expires` int(11) NOT NULL DEFAULT 0,
1030 `scope` varchar(200) NOT NULL DEFAULT '',
1031 `uid` int(11) NOT NULL DEFAULT 0,
1033 ) DEFAULT CHARSET=utf8;
1038 CREATE TABLE IF NOT EXISTS `user` (
1039 `uid` int(11) NOT NULL auto_increment,
1040 `guid` varchar(64) NOT NULL DEFAULT '',
1041 `username` varchar(255) NOT NULL DEFAULT '',
1042 `password` varchar(255) NOT NULL DEFAULT '',
1043 `nickname` varchar(255) NOT NULL DEFAULT '',
1044 `email` varchar(255) NOT NULL DEFAULT '',
1045 `openid` varchar(255) NOT NULL DEFAULT '',
1046 `timezone` varchar(128) NOT NULL DEFAULT '',
1047 `language` varchar(32) NOT NULL DEFAULT 'en',
1048 `register_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1049 `login_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1050 `default-location` varchar(255) NOT NULL DEFAULT '',
1051 `allow_location` tinyint(1) NOT NULL DEFAULT 0,
1052 `theme` varchar(255) NOT NULL DEFAULT '',
1053 `pubkey` text NOT NULL,
1054 `prvkey` text NOT NULL,
1055 `spubkey` text NOT NULL,
1056 `sprvkey` text NOT NULL,
1057 `verified` tinyint(1) unsigned NOT NULL DEFAULT 0,
1058 `blocked` tinyint(1) unsigned NOT NULL DEFAULT 0,
1059 `blockwall` tinyint(1) unsigned NOT NULL DEFAULT 0,
1060 `hidewall` tinyint(1) unsigned NOT NULL DEFAULT 0,
1061 `blocktags` tinyint(1) unsigned NOT NULL DEFAULT 0,
1062 `unkmail` tinyint(1) NOT NULL DEFAULT 0,
1063 `cntunkmail` int(11) NOT NULL DEFAULT 10,
1064 `notify-flags` int(11) unsigned NOT NULL DEFAULT 65535,
1065 `page-flags` int(11) unsigned NOT NULL DEFAULT 0,
1066 `prvnets` tinyint(1) NOT NULL DEFAULT 0,
1067 `pwdreset` varchar(255) NOT NULL DEFAULT '',
1068 `maxreq` int(11) NOT NULL DEFAULT 10,
1069 `expire` int(11) unsigned NOT NULL DEFAULT 0,
1070 `account_removed` tinyint(1) NOT NULL DEFAULT 0,
1071 `account_expired` tinyint(1) NOT NULL DEFAULT 0,
1072 `account_expires_on` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1073 `expire_notification_sent` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1074 `service_class` varchar(32) NOT NULL DEFAULT '',
1075 `def_gid` int(11) NOT NULL DEFAULT 0,
1076 `allow_cid` mediumtext NOT NULL,
1077 `allow_gid` mediumtext NOT NULL,
1078 `deny_cid` mediumtext NOT NULL,
1079 `deny_gid` mediumtext NOT NULL,
1080 `openidserver` text NOT NULL,
1082 INDEX `nickname` (`nickname`)
1083 ) DEFAULT CHARSET=utf8;
1088 CREATE TABLE IF NOT EXISTS `userd` (
1089 `id` int(11) NOT NULL auto_increment,
1090 `username` varchar(255) NOT NULL,
1092 INDEX `username` (`username`)
1093 ) DEFAULT CHARSET=utf8;
1096 -- TABLE workerqueue
1098 CREATE TABLE IF NOT EXISTS `workerqueue` (
1099 `id` int(11) NOT NULL auto_increment,
1100 `parameter` text NOT NULL,
1101 `priority` tinyint(3) unsigned NOT NULL DEFAULT 0,
1102 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1103 `pid` int(11) NOT NULL DEFAULT 0,
1104 `executed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1106 INDEX `created` (`created`)
1107 ) DEFAULT CHARSET=utf8;