1 -- ------------------------------------------
2 -- Friendica 3.5-dev (Asparagus)
3 -- DB_UPDATE_VERSION 1194
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 `avatar` varchar(255) NOT NULL DEFAULT '',
123 `photo` text NOT NULL,
124 `thumb` text NOT NULL,
125 `micro` text NOT NULL,
126 `site-pubkey` text NOT NULL,
127 `issued-id` varchar(255) NOT NULL DEFAULT '',
128 `dfrn-id` varchar(255) NOT NULL DEFAULT '',
129 `url` varchar(255) NOT NULL DEFAULT '',
130 `nurl` varchar(255) NOT NULL DEFAULT '',
131 `addr` varchar(255) NOT NULL DEFAULT '',
132 `alias` varchar(255) NOT NULL DEFAULT '',
133 `pubkey` text NOT NULL,
134 `prvkey` text NOT NULL,
135 `batch` varchar(255) NOT NULL DEFAULT '',
136 `request` text NOT NULL,
137 `notify` text NOT NULL,
138 `poll` text NOT NULL,
139 `confirm` text NOT NULL,
140 `poco` text NOT NULL,
141 `aes_allow` tinyint(1) NOT NULL DEFAULT 0,
142 `ret-aes` tinyint(1) NOT NULL DEFAULT 0,
143 `usehub` tinyint(1) NOT NULL DEFAULT 0,
144 `subhub` tinyint(1) NOT NULL DEFAULT 0,
145 `hub-verify` varchar(255) NOT NULL DEFAULT '',
146 `last-update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
147 `success_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
148 `failure_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
149 `name-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
150 `uri-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
151 `avatar-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
152 `term-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
153 `last-item` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
154 `priority` tinyint(3) NOT NULL DEFAULT 0,
155 `blocked` tinyint(1) NOT NULL DEFAULT 1,
156 `readonly` tinyint(1) NOT NULL DEFAULT 0,
157 `writable` tinyint(1) NOT NULL DEFAULT 0,
158 `forum` tinyint(1) NOT NULL DEFAULT 0,
159 `prv` tinyint(1) NOT NULL DEFAULT 0,
160 `hidden` tinyint(1) NOT NULL DEFAULT 0,
161 `archive` tinyint(1) NOT NULL DEFAULT 0,
162 `pending` tinyint(1) NOT NULL DEFAULT 1,
163 `rating` tinyint(1) NOT NULL DEFAULT 0,
164 `reason` text NOT NULL,
165 `closeness` tinyint(2) NOT NULL DEFAULT 99,
166 `info` mediumtext NOT NULL,
167 `profile-id` int(11) NOT NULL DEFAULT 0,
168 `bdyear` varchar(4) NOT NULL DEFAULT '',
169 `bd` date NOT NULL DEFAULT '0000-00-00',
170 `notify_new_posts` tinyint(1) NOT NULL DEFAULT 0,
171 `fetch_further_information` tinyint(1) NOT NULL DEFAULT 0,
172 `ffi_keyword_blacklist` mediumtext NOT NULL,
175 ) DEFAULT CHARSET=utf8;
180 CREATE TABLE IF NOT EXISTS `conv` (
181 `id` int(10) unsigned NOT NULL auto_increment,
182 `guid` varchar(64) NOT NULL DEFAULT '',
183 `recips` mediumtext NOT NULL,
184 `uid` int(11) NOT NULL DEFAULT 0,
185 `creator` varchar(255) NOT NULL DEFAULT '',
186 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
187 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
188 `subject` mediumtext NOT NULL,
191 ) DEFAULT CHARSET=utf8;
196 CREATE TABLE IF NOT EXISTS `deliverq` (
197 `id` int(10) unsigned NOT NULL auto_increment,
198 `cmd` varchar(32) NOT NULL DEFAULT '',
199 `item` int(11) NOT NULL DEFAULT 0,
200 `contact` int(11) NOT NULL DEFAULT 0,
202 ) DEFAULT CHARSET=utf8;
207 CREATE TABLE IF NOT EXISTS `dsprphotoq` (
208 `id` int(10) unsigned NOT NULL auto_increment,
209 `uid` int(11) NOT NULL DEFAULT 0,
210 `msg` mediumtext NOT NULL,
211 `attempt` tinyint(4) NOT NULL DEFAULT 0,
213 ) DEFAULT CHARSET=utf8;
218 CREATE TABLE IF NOT EXISTS `event` (
219 `id` int(11) NOT NULL auto_increment,
220 `uid` int(11) NOT NULL DEFAULT 0,
221 `cid` int(11) NOT NULL DEFAULT 0,
222 `uri` varchar(255) NOT NULL DEFAULT '',
223 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
224 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
225 `start` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
226 `finish` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
227 `summary` text NOT NULL,
228 `desc` text NOT NULL,
229 `location` text NOT NULL,
230 `type` varchar(255) NOT NULL DEFAULT '',
231 `nofinish` tinyint(1) NOT NULL DEFAULT 0,
232 `adjust` tinyint(1) NOT NULL DEFAULT 1,
233 `ignore` tinyint(1) unsigned NOT NULL DEFAULT 0,
234 `allow_cid` mediumtext NOT NULL,
235 `allow_gid` mediumtext NOT NULL,
236 `deny_cid` mediumtext NOT NULL,
237 `deny_gid` mediumtext NOT NULL,
240 ) DEFAULT CHARSET=utf8;
245 CREATE TABLE IF NOT EXISTS `fcontact` (
246 `id` int(10) unsigned NOT NULL auto_increment,
247 `url` varchar(255) NOT NULL DEFAULT '',
248 `name` varchar(255) NOT NULL DEFAULT '',
249 `photo` varchar(255) NOT NULL DEFAULT '',
250 `request` varchar(255) NOT NULL DEFAULT '',
251 `nick` varchar(255) NOT NULL DEFAULT '',
252 `addr` varchar(255) NOT NULL DEFAULT '',
253 `batch` varchar(255) NOT NULL DEFAULT '',
254 `notify` varchar(255) NOT NULL DEFAULT '',
255 `poll` varchar(255) NOT NULL DEFAULT '',
256 `confirm` varchar(255) NOT NULL DEFAULT '',
257 `priority` tinyint(1) NOT NULL DEFAULT 0,
258 `network` varchar(32) NOT NULL DEFAULT '',
259 `alias` varchar(255) NOT NULL DEFAULT '',
260 `pubkey` text NOT NULL,
261 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
263 INDEX `addr` (`addr`)
264 ) DEFAULT CHARSET=utf8;
269 CREATE TABLE IF NOT EXISTS `ffinder` (
270 `id` int(10) unsigned NOT NULL auto_increment,
271 `uid` int(10) unsigned NOT NULL DEFAULT 0,
272 `cid` int(10) unsigned NOT NULL DEFAULT 0,
273 `fid` int(10) unsigned NOT NULL DEFAULT 0,
275 ) DEFAULT CHARSET=utf8;
280 CREATE TABLE IF NOT EXISTS `fserver` (
281 `id` int(11) NOT NULL auto_increment,
282 `server` varchar(255) NOT NULL DEFAULT '',
283 `posturl` varchar(255) NOT NULL DEFAULT '',
286 INDEX `server` (`server`)
287 ) DEFAULT CHARSET=utf8;
292 CREATE TABLE IF NOT EXISTS `fsuggest` (
293 `id` int(11) NOT NULL auto_increment,
294 `uid` int(11) NOT NULL DEFAULT 0,
295 `cid` int(11) NOT NULL DEFAULT 0,
296 `name` varchar(255) NOT NULL DEFAULT '',
297 `url` varchar(255) NOT NULL DEFAULT '',
298 `request` varchar(255) NOT NULL DEFAULT '',
299 `photo` varchar(255) NOT NULL DEFAULT '',
300 `note` text NOT NULL,
301 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
303 ) DEFAULT CHARSET=utf8;
308 CREATE TABLE IF NOT EXISTS `gcign` (
309 `id` int(11) NOT NULL auto_increment,
310 `uid` int(11) NOT NULL DEFAULT 0,
311 `gcid` int(11) NOT NULL DEFAULT 0,
314 INDEX `gcid` (`gcid`)
315 ) DEFAULT CHARSET=utf8;
320 CREATE TABLE IF NOT EXISTS `gcontact` (
321 `id` int(10) unsigned NOT NULL auto_increment,
322 `name` varchar(255) NOT NULL DEFAULT '',
323 `nick` varchar(255) NOT NULL DEFAULT '',
324 `url` varchar(255) NOT NULL DEFAULT '',
325 `nurl` varchar(255) NOT NULL DEFAULT '',
326 `photo` varchar(255) NOT NULL DEFAULT '',
327 `connect` varchar(255) NOT NULL DEFAULT '',
328 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
329 `updated` datetime DEFAULT '0000-00-00 00:00:00',
330 `last_contact` datetime DEFAULT '0000-00-00 00:00:00',
331 `last_failure` datetime DEFAULT '0000-00-00 00:00:00',
332 `location` varchar(255) NOT NULL DEFAULT '',
333 `about` text NOT NULL,
334 `keywords` text NOT NULL,
335 `gender` varchar(32) NOT NULL DEFAULT '',
336 `birthday` varchar(32) NOT NULL DEFAULT '0000-00-00',
337 `community` tinyint(1) NOT NULL DEFAULT 0,
338 `hide` tinyint(1) NOT NULL DEFAULT 0,
339 `nsfw` tinyint(1) NOT NULL DEFAULT 0,
340 `network` varchar(255) NOT NULL DEFAULT '',
341 `addr` varchar(255) NOT NULL DEFAULT '',
342 `notify` text NOT NULL,
343 `alias` varchar(255) NOT NULL DEFAULT '',
344 `generation` tinyint(3) NOT NULL DEFAULT 0,
345 `server_url` varchar(255) NOT NULL DEFAULT '',
347 INDEX `nurl` (`nurl`),
348 INDEX `updated` (`updated`)
349 ) DEFAULT CHARSET=utf8;
354 CREATE TABLE IF NOT EXISTS `glink` (
355 `id` int(10) unsigned NOT NULL auto_increment,
356 `cid` int(11) NOT NULL DEFAULT 0,
357 `uid` int(11) NOT NULL DEFAULT 0,
358 `gcid` int(11) NOT NULL DEFAULT 0,
359 `zcid` int(11) NOT NULL DEFAULT 0,
360 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
362 INDEX `cid_uid_gcid_zcid` (`cid`,`uid`,`gcid`,`zcid`),
363 INDEX `gcid` (`gcid`),
364 INDEX `zcid` (`zcid`)
365 ) DEFAULT CHARSET=utf8;
370 CREATE TABLE IF NOT EXISTS `group` (
371 `id` int(10) unsigned NOT NULL auto_increment,
372 `uid` int(10) unsigned NOT NULL DEFAULT 0,
373 `visible` tinyint(1) NOT NULL DEFAULT 0,
374 `deleted` tinyint(1) NOT NULL DEFAULT 0,
375 `name` varchar(255) NOT NULL DEFAULT '',
378 ) DEFAULT CHARSET=utf8;
381 -- TABLE group_member
383 CREATE TABLE IF NOT EXISTS `group_member` (
384 `id` int(10) unsigned NOT NULL auto_increment,
385 `uid` int(10) unsigned NOT NULL DEFAULT 0,
386 `gid` int(10) unsigned NOT NULL DEFAULT 0,
387 `contact-id` int(10) unsigned NOT NULL DEFAULT 0,
389 INDEX `uid_gid_contactid` (`uid`,`gid`,`contact-id`)
390 ) DEFAULT CHARSET=utf8;
395 CREATE TABLE IF NOT EXISTS `gserver` (
396 `id` int(10) unsigned NOT NULL auto_increment,
397 `url` varchar(255) NOT NULL DEFAULT '',
398 `nurl` varchar(255) NOT NULL DEFAULT '',
399 `version` varchar(255) NOT NULL DEFAULT '',
400 `site_name` varchar(255) NOT NULL DEFAULT '',
401 `info` text NOT NULL,
402 `register_policy` tinyint(1) NOT NULL DEFAULT 0,
403 `poco` varchar(255) NOT NULL DEFAULT '',
404 `noscrape` varchar(255) NOT NULL DEFAULT '',
405 `network` varchar(32) NOT NULL DEFAULT '',
406 `platform` varchar(255) NOT NULL DEFAULT '',
407 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
408 `last_poco_query` datetime DEFAULT '0000-00-00 00:00:00',
409 `last_contact` datetime DEFAULT '0000-00-00 00:00:00',
410 `last_failure` datetime DEFAULT '0000-00-00 00:00:00',
412 INDEX `nurl` (`nurl`)
413 ) DEFAULT CHARSET=utf8;
418 CREATE TABLE IF NOT EXISTS `hook` (
419 `id` int(11) NOT NULL auto_increment,
420 `hook` varchar(255) NOT NULL DEFAULT '',
421 `file` varchar(255) NOT NULL DEFAULT '',
422 `function` varchar(255) NOT NULL DEFAULT '',
423 `priority` int(11) unsigned NOT NULL DEFAULT 0,
425 INDEX `hook_file_function` (`hook`(30),`file`(60),`function`(30))
426 ) DEFAULT CHARSET=utf8;
431 CREATE TABLE IF NOT EXISTS `intro` (
432 `id` int(10) unsigned NOT NULL auto_increment,
433 `uid` int(10) unsigned NOT NULL DEFAULT 0,
434 `fid` int(11) NOT NULL DEFAULT 0,
435 `contact-id` int(11) NOT NULL DEFAULT 0,
436 `knowyou` tinyint(1) NOT NULL DEFAULT 0,
437 `duplex` tinyint(1) NOT NULL DEFAULT 0,
438 `note` text NOT NULL,
439 `hash` varchar(255) NOT NULL DEFAULT '',
440 `datetime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
441 `blocked` tinyint(1) NOT NULL DEFAULT 1,
442 `ignore` tinyint(1) NOT NULL DEFAULT 0,
444 ) DEFAULT CHARSET=utf8;
449 CREATE TABLE IF NOT EXISTS `item` (
450 `id` int(10) unsigned NOT NULL auto_increment,
451 `guid` varchar(255) NOT NULL DEFAULT '',
452 `uri` varchar(255) NOT NULL DEFAULT '',
453 `uid` int(10) unsigned NOT NULL DEFAULT 0,
454 `contact-id` int(11) NOT NULL DEFAULT 0,
455 `gcontact-id` int(11) unsigned NOT NULL DEFAULT 0,
456 `type` varchar(255) NOT NULL DEFAULT '',
457 `wall` tinyint(1) NOT NULL DEFAULT 0,
458 `gravity` tinyint(1) NOT NULL DEFAULT 0,
459 `parent` int(10) unsigned NOT NULL DEFAULT 0,
460 `parent-uri` varchar(255) NOT NULL DEFAULT '',
461 `extid` varchar(255) NOT NULL DEFAULT '',
462 `thr-parent` varchar(255) NOT NULL DEFAULT '',
463 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
464 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
465 `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
466 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
467 `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
468 `owner-name` varchar(255) NOT NULL DEFAULT '',
469 `owner-link` varchar(255) NOT NULL DEFAULT '',
470 `owner-avatar` varchar(255) NOT NULL DEFAULT '',
471 `author-name` varchar(255) NOT NULL DEFAULT '',
472 `author-link` varchar(255) NOT NULL DEFAULT '',
473 `author-avatar` varchar(255) NOT NULL DEFAULT '',
474 `title` varchar(255) NOT NULL DEFAULT '',
475 `body` mediumtext NOT NULL,
476 `app` varchar(255) NOT NULL DEFAULT '',
477 `verb` varchar(255) NOT NULL DEFAULT '',
478 `object-type` varchar(255) NOT NULL DEFAULT '',
479 `object` text NOT NULL,
480 `target-type` varchar(255) NOT NULL DEFAULT '',
481 `target` text NOT NULL,
482 `postopts` text NOT NULL,
483 `plink` varchar(255) NOT NULL DEFAULT '',
484 `resource-id` varchar(255) NOT NULL DEFAULT '',
485 `event-id` int(11) NOT NULL DEFAULT 0,
486 `tag` mediumtext NOT NULL,
487 `attach` mediumtext NOT NULL,
488 `inform` mediumtext NOT NULL,
489 `file` mediumtext NOT NULL,
490 `location` varchar(255) NOT NULL DEFAULT '',
491 `coord` varchar(255) NOT NULL DEFAULT '',
492 `allow_cid` mediumtext NOT NULL,
493 `allow_gid` mediumtext NOT NULL,
494 `deny_cid` mediumtext NOT NULL,
495 `deny_gid` mediumtext NOT NULL,
496 `private` tinyint(1) NOT NULL DEFAULT 0,
497 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
498 `moderated` tinyint(1) NOT NULL DEFAULT 0,
499 `visible` tinyint(1) NOT NULL DEFAULT 0,
500 `spam` tinyint(1) NOT NULL DEFAULT 0,
501 `starred` tinyint(1) NOT NULL DEFAULT 0,
502 `bookmark` tinyint(1) NOT NULL DEFAULT 0,
503 `unseen` tinyint(1) NOT NULL DEFAULT 1,
504 `deleted` tinyint(1) NOT NULL DEFAULT 0,
505 `origin` tinyint(1) NOT NULL DEFAULT 0,
506 `forum_mode` tinyint(1) NOT NULL DEFAULT 0,
507 `last-child` tinyint(1) unsigned NOT NULL DEFAULT 1,
508 `mention` tinyint(1) NOT NULL DEFAULT 0,
509 `network` varchar(32) NOT NULL DEFAULT '',
510 `rendered-hash` varchar(32) NOT NULL DEFAULT '',
511 `rendered-html` mediumtext NOT NULL,
512 `global` tinyint(1) NOT NULL DEFAULT 0,
514 INDEX `guid` (`guid`),
516 INDEX `parent` (`parent`),
517 INDEX `parent-uri` (`parent-uri`),
518 INDEX `extid` (`extid`),
519 INDEX `uid_id` (`uid`,`id`),
520 INDEX `uid_created` (`uid`,`created`),
521 INDEX `uid_unseen` (`uid`,`unseen`),
522 INDEX `uid_network_received` (`uid`,`network`,`received`),
523 INDEX `uid_received` (`uid`,`received`),
524 INDEX `uid_network_commented` (`uid`,`network`,`commented`),
525 INDEX `uid_commented` (`uid`,`commented`),
526 INDEX `uid_title` (`uid`,`title`),
527 INDEX `uid_thrparent` (`uid`,`thr-parent`),
528 INDEX `uid_parenturi` (`uid`,`parent-uri`),
529 INDEX `uid_contactid_created` (`uid`,`contact-id`,`created`),
530 INDEX `gcontactid_uid_created` (`gcontact-id`,`uid`,`created`),
531 INDEX `wall_body` (`wall`,`body`(6)),
532 INDEX `uid_visible_moderated_created` (`uid`,`visible`,`moderated`,`created`),
533 INDEX `uid_uri` (`uid`,`uri`),
534 INDEX `uid_wall_created` (`uid`,`wall`,`created`),
535 INDEX `resource-id` (`resource-id`),
536 INDEX `uid_type` (`uid`,`type`),
537 INDEX `uid_starred` (`uid`,`starred`),
538 INDEX `contactid_allowcid_allowpid_denycid_denygid` (`contact-id`,`allow_cid`(10),`allow_gid`(10),`deny_cid`(10),`deny_gid`(10)),
539 INDEX `uid_wall_parent_created` (`uid`,`wall`,`parent`,`created`),
540 INDEX `uid_type_changed` (`uid`,`type`,`changed`),
541 INDEX `contactid_verb` (`contact-id`,`verb`),
542 INDEX `deleted_changed` (`deleted`,`changed`),
543 INDEX `uid_wall_changed` (`uid`,`wall`,`changed`),
544 INDEX `uid_eventid` (`uid`,`event-id`),
545 INDEX `uid_authorlink` (`uid`,`author-link`),
546 INDEX `uid_ownerlink` (`uid`,`owner-link`)
547 ) DEFAULT CHARSET=utf8;
552 CREATE TABLE IF NOT EXISTS `item_id` (
553 `id` int(11) NOT NULL auto_increment,
554 `iid` int(11) NOT NULL DEFAULT 0,
555 `uid` int(11) NOT NULL DEFAULT 0,
556 `sid` varchar(255) NOT NULL DEFAULT '',
557 `service` varchar(255) NOT NULL DEFAULT '',
561 INDEX `service` (`service`),
563 ) DEFAULT CHARSET=utf8;
568 CREATE TABLE IF NOT EXISTS `locks` (
569 `id` int(11) NOT NULL auto_increment,
570 `name` varchar(128) NOT NULL DEFAULT '',
571 `locked` tinyint(1) NOT NULL DEFAULT 0,
572 `created` datetime DEFAULT '0000-00-00 00:00:00',
574 ) DEFAULT CHARSET=utf8;
579 CREATE TABLE IF NOT EXISTS `mail` (
580 `id` int(10) unsigned NOT NULL auto_increment,
581 `uid` int(10) unsigned NOT NULL DEFAULT 0,
582 `guid` varchar(64) NOT NULL DEFAULT '',
583 `from-name` varchar(255) NOT NULL DEFAULT '',
584 `from-photo` varchar(255) NOT NULL DEFAULT '',
585 `from-url` varchar(255) NOT NULL DEFAULT '',
586 `contact-id` varchar(255) NOT NULL DEFAULT '',
587 `convid` int(11) unsigned NOT NULL DEFAULT 0,
588 `title` varchar(255) NOT NULL DEFAULT '',
589 `body` mediumtext NOT NULL,
590 `seen` tinyint(1) NOT NULL DEFAULT 0,
591 `reply` tinyint(1) NOT NULL DEFAULT 0,
592 `replied` tinyint(1) NOT NULL DEFAULT 0,
593 `unknown` tinyint(1) NOT NULL DEFAULT 0,
594 `uri` varchar(255) NOT NULL DEFAULT '',
595 `parent-uri` varchar(255) NOT NULL DEFAULT '',
596 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
599 INDEX `guid` (`guid`),
600 INDEX `convid` (`convid`),
601 INDEX `reply` (`reply`),
603 INDEX `parent-uri` (`parent-uri`)
604 ) DEFAULT CHARSET=utf8;
609 CREATE TABLE IF NOT EXISTS `mailacct` (
610 `id` int(11) NOT NULL auto_increment,
611 `uid` int(11) NOT NULL DEFAULT 0,
612 `server` varchar(255) NOT NULL DEFAULT '',
613 `port` int(11) NOT NULL DEFAULT 0,
614 `ssltype` varchar(16) NOT NULL DEFAULT '',
615 `mailbox` varchar(255) NOT NULL DEFAULT '',
616 `user` varchar(255) NOT NULL DEFAULT '',
617 `pass` text NOT NULL,
618 `reply_to` varchar(255) NOT NULL DEFAULT '',
619 `action` int(11) NOT NULL DEFAULT 0,
620 `movetofolder` varchar(255) NOT NULL DEFAULT '',
621 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
622 `last_check` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
624 ) DEFAULT CHARSET=utf8;
629 CREATE TABLE IF NOT EXISTS `manage` (
630 `id` int(11) NOT NULL auto_increment,
631 `uid` int(11) NOT NULL DEFAULT 0,
632 `mid` int(11) NOT NULL DEFAULT 0,
634 INDEX `uid_mid` (`uid`,`mid`)
635 ) DEFAULT CHARSET=utf8;
640 CREATE TABLE IF NOT EXISTS `notify` (
641 `id` int(11) NOT NULL auto_increment,
642 `hash` varchar(64) NOT NULL DEFAULT '',
643 `type` int(11) NOT NULL DEFAULT 0,
644 `name` varchar(255) NOT NULL DEFAULT '',
645 `url` varchar(255) NOT NULL DEFAULT '',
646 `photo` varchar(255) NOT NULL DEFAULT '',
647 `date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
648 `msg` mediumtext NOT NULL,
649 `uid` int(11) NOT NULL DEFAULT 0,
650 `link` varchar(255) NOT NULL DEFAULT '',
651 `iid` int(11) NOT NULL DEFAULT 0,
652 `parent` int(11) NOT NULL DEFAULT 0,
653 `seen` tinyint(1) NOT NULL DEFAULT 0,
654 `verb` varchar(255) NOT NULL DEFAULT '',
655 `otype` varchar(16) NOT NULL DEFAULT '',
658 ) DEFAULT CHARSET=utf8;
661 -- TABLE notify-threads
663 CREATE TABLE IF NOT EXISTS `notify-threads` (
664 `id` int(11) NOT NULL auto_increment,
665 `notify-id` int(11) NOT NULL DEFAULT 0,
666 `master-parent-item` int(10) unsigned NOT NULL DEFAULT 0,
667 `parent-item` int(10) unsigned NOT NULL DEFAULT 0,
668 `receiver-uid` int(11) NOT NULL DEFAULT 0,
670 INDEX `master-parent-item` (`master-parent-item`),
671 INDEX `receiver-uid` (`receiver-uid`)
672 ) DEFAULT CHARSET=utf8;
677 CREATE TABLE IF NOT EXISTS `oembed` (
678 `url` varchar(255) NOT NULL,
679 `content` text NOT NULL,
680 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
682 INDEX `created` (`created`)
683 ) DEFAULT CHARSET=utf8;
688 CREATE TABLE IF NOT EXISTS `parsed_url` (
689 `url` varchar(255) NOT NULL,
690 `guessing` tinyint(1) NOT NULL DEFAULT 0,
691 `oembed` tinyint(1) NOT NULL DEFAULT 0,
692 `content` text NOT NULL,
693 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
694 PRIMARY KEY(`url`,`guessing`,`oembed`),
695 INDEX `created` (`created`)
696 ) DEFAULT CHARSET=utf8;
701 CREATE TABLE IF NOT EXISTS `pconfig` (
702 `id` int(11) NOT NULL auto_increment,
703 `uid` int(11) NOT NULL DEFAULT 0,
704 `cat` varchar(255) NOT NULL DEFAULT '',
705 `k` varchar(255) NOT NULL DEFAULT '',
706 `v` mediumtext NOT NULL,
708 INDEX `uid_cat_k` (`uid`,`cat`(30),`k`(30))
709 ) DEFAULT CHARSET=utf8;
714 CREATE TABLE IF NOT EXISTS `photo` (
715 `id` int(10) unsigned NOT NULL auto_increment,
716 `uid` int(10) unsigned NOT NULL DEFAULT 0,
717 `contact-id` int(10) unsigned NOT NULL DEFAULT 0,
718 `guid` varchar(64) NOT NULL DEFAULT '',
719 `resource-id` varchar(255) NOT NULL DEFAULT '',
720 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
721 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
722 `title` varchar(255) NOT NULL DEFAULT '',
723 `desc` text NOT NULL,
724 `album` varchar(255) NOT NULL DEFAULT '',
725 `filename` varchar(255) NOT NULL DEFAULT '',
726 `type` varchar(128) NOT NULL DEFAULT 'image/jpeg',
727 `height` smallint(6) NOT NULL DEFAULT 0,
728 `width` smallint(6) NOT NULL DEFAULT 0,
729 `datasize` int(10) unsigned NOT NULL DEFAULT 0,
730 `data` mediumblob NOT NULL,
731 `scale` tinyint(3) NOT NULL DEFAULT 0,
732 `profile` tinyint(1) NOT NULL DEFAULT 0,
733 `allow_cid` mediumtext NOT NULL,
734 `allow_gid` mediumtext NOT NULL,
735 `deny_cid` mediumtext NOT NULL,
736 `deny_gid` mediumtext NOT NULL,
739 INDEX `resource-id` (`resource-id`),
740 INDEX `guid` (`guid`)
741 ) DEFAULT CHARSET=utf8;
746 CREATE TABLE IF NOT EXISTS `poll` (
747 `id` int(11) NOT NULL auto_increment,
748 `uid` int(11) NOT NULL DEFAULT 0,
749 `q0` mediumtext NOT NULL,
750 `q1` mediumtext NOT NULL,
751 `q2` mediumtext NOT NULL,
752 `q3` mediumtext NOT NULL,
753 `q4` mediumtext NOT NULL,
754 `q5` mediumtext NOT NULL,
755 `q6` mediumtext NOT NULL,
756 `q7` mediumtext NOT NULL,
757 `q8` mediumtext NOT NULL,
758 `q9` mediumtext NOT NULL,
761 ) DEFAULT CHARSET=utf8;
766 CREATE TABLE IF NOT EXISTS `poll_result` (
767 `id` int(11) NOT NULL auto_increment,
768 `poll_id` int(11) NOT NULL DEFAULT 0,
769 `choice` int(11) NOT NULL DEFAULT 0,
771 INDEX `poll_id` (`poll_id`),
772 INDEX `choice` (`choice`)
773 ) DEFAULT CHARSET=utf8;
778 CREATE TABLE IF NOT EXISTS `profile` (
779 `id` int(11) NOT NULL auto_increment,
780 `uid` int(11) NOT NULL DEFAULT 0,
781 `profile-name` varchar(255) NOT NULL DEFAULT '',
782 `is-default` tinyint(1) NOT NULL DEFAULT 0,
783 `hide-friends` tinyint(1) NOT NULL DEFAULT 0,
784 `name` varchar(255) NOT NULL DEFAULT '',
785 `pdesc` varchar(255) NOT NULL DEFAULT '',
786 `dob` varchar(32) NOT NULL DEFAULT '0000-00-00',
787 `address` varchar(255) NOT NULL DEFAULT '',
788 `locality` varchar(255) NOT NULL DEFAULT '',
789 `region` varchar(255) NOT NULL DEFAULT '',
790 `postal-code` varchar(32) NOT NULL DEFAULT '',
791 `country-name` varchar(255) NOT NULL DEFAULT '',
792 `hometown` varchar(255) NOT NULL DEFAULT '',
793 `gender` varchar(32) NOT NULL DEFAULT '',
794 `marital` varchar(255) NOT NULL DEFAULT '',
795 `with` text NOT NULL,
796 `howlong` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
797 `sexual` varchar(255) NOT NULL DEFAULT '',
798 `politic` varchar(255) NOT NULL DEFAULT '',
799 `religion` varchar(255) NOT NULL DEFAULT '',
800 `pub_keywords` text NOT NULL,
801 `prv_keywords` text NOT NULL,
802 `likes` text NOT NULL,
803 `dislikes` text NOT NULL,
804 `about` text NOT NULL,
805 `summary` varchar(255) NOT NULL DEFAULT '',
806 `music` text NOT NULL,
807 `book` text NOT NULL,
809 `film` text NOT NULL,
810 `interest` text NOT NULL,
811 `romance` text NOT NULL,
812 `work` text NOT NULL,
813 `education` text NOT NULL,
814 `contact` text NOT NULL,
815 `homepage` varchar(255) NOT NULL DEFAULT '',
816 `photo` varchar(255) NOT NULL DEFAULT '',
817 `thumb` varchar(255) NOT NULL DEFAULT '',
818 `publish` tinyint(1) NOT NULL DEFAULT 0,
819 `net-publish` tinyint(1) NOT NULL DEFAULT 0,
821 INDEX `hometown` (`hometown`)
822 ) DEFAULT CHARSET=utf8;
825 -- TABLE profile_check
827 CREATE TABLE IF NOT EXISTS `profile_check` (
828 `id` int(10) unsigned NOT NULL auto_increment,
829 `uid` int(10) unsigned NOT NULL DEFAULT 0,
830 `cid` int(10) unsigned NOT NULL DEFAULT 0,
831 `dfrn_id` varchar(255) NOT NULL DEFAULT '',
832 `sec` varchar(255) NOT NULL DEFAULT '',
833 `expire` int(11) NOT NULL DEFAULT 0,
835 ) DEFAULT CHARSET=utf8;
838 -- TABLE push_subscriber
840 CREATE TABLE IF NOT EXISTS `push_subscriber` (
841 `id` int(11) NOT NULL auto_increment,
842 `uid` int(11) NOT NULL DEFAULT 0,
843 `callback_url` varchar(255) NOT NULL DEFAULT '',
844 `topic` varchar(255) NOT NULL DEFAULT '',
845 `nickname` varchar(255) NOT NULL DEFAULT '',
846 `push` int(11) NOT NULL DEFAULT 0,
847 `last_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
848 `secret` varchar(255) NOT NULL DEFAULT '',
850 ) DEFAULT CHARSET=utf8;
855 CREATE TABLE IF NOT EXISTS `queue` (
856 `id` int(11) NOT NULL auto_increment,
857 `cid` int(11) NOT NULL DEFAULT 0,
858 `network` varchar(32) NOT NULL DEFAULT '',
859 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
860 `last` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
861 `content` mediumtext NOT NULL,
862 `batch` tinyint(1) NOT NULL DEFAULT 0,
865 INDEX `created` (`created`),
866 INDEX `last` (`last`),
867 INDEX `network` (`network`),
868 INDEX `batch` (`batch`)
869 ) DEFAULT CHARSET=utf8;
874 CREATE TABLE IF NOT EXISTS `register` (
875 `id` int(11) unsigned NOT NULL auto_increment,
876 `hash` varchar(255) NOT NULL DEFAULT '',
877 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
878 `uid` int(11) unsigned NOT NULL DEFAULT 0,
879 `password` varchar(255) NOT NULL DEFAULT '',
880 `language` varchar(16) NOT NULL DEFAULT '',
882 ) DEFAULT CHARSET=utf8;
887 CREATE TABLE IF NOT EXISTS `search` (
888 `id` int(11) NOT NULL auto_increment,
889 `uid` int(11) NOT NULL DEFAULT 0,
890 `term` varchar(255) NOT NULL DEFAULT '',
893 INDEX `term` (`term`)
894 ) DEFAULT CHARSET=utf8;
899 CREATE TABLE IF NOT EXISTS `session` (
900 `id` bigint(20) unsigned NOT NULL auto_increment,
901 `sid` varchar(255) NOT NULL DEFAULT '',
902 `data` text NOT NULL,
903 `expire` int(10) unsigned NOT NULL DEFAULT 0,
906 INDEX `expire` (`expire`)
907 ) DEFAULT CHARSET=utf8;
912 CREATE TABLE IF NOT EXISTS `sign` (
913 `id` int(10) unsigned NOT NULL auto_increment,
914 `iid` int(10) unsigned NOT NULL DEFAULT 0,
915 `retract_iid` int(10) unsigned NOT NULL DEFAULT 0,
916 `signed_text` mediumtext NOT NULL,
917 `signature` text NOT NULL,
918 `signer` varchar(255) NOT NULL DEFAULT '',
921 INDEX `retract_iid` (`retract_iid`)
922 ) DEFAULT CHARSET=utf8;
927 CREATE TABLE IF NOT EXISTS `spam` (
928 `id` int(11) NOT NULL auto_increment,
929 `uid` int(11) NOT NULL DEFAULT 0,
930 `spam` int(11) NOT NULL DEFAULT 0,
931 `ham` int(11) NOT NULL DEFAULT 0,
932 `term` varchar(255) NOT NULL DEFAULT '',
933 `date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
936 INDEX `spam` (`spam`),
938 INDEX `term` (`term`)
939 ) DEFAULT CHARSET=utf8;
944 CREATE TABLE IF NOT EXISTS `term` (
945 `tid` int(10) unsigned NOT NULL auto_increment,
946 `oid` int(10) unsigned NOT NULL DEFAULT 0,
947 `otype` tinyint(3) unsigned NOT NULL DEFAULT 0,
948 `type` tinyint(3) unsigned NOT NULL DEFAULT 0,
949 `term` varchar(255) NOT NULL DEFAULT '',
950 `url` varchar(255) NOT NULL DEFAULT '',
951 `guid` varchar(255) NOT NULL DEFAULT '',
952 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
953 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
954 `global` tinyint(1) NOT NULL DEFAULT 0,
955 `aid` int(10) unsigned NOT NULL DEFAULT 0,
956 `uid` int(10) unsigned NOT NULL DEFAULT 0,
958 INDEX `oid_otype_type_term` (`oid`,`otype`,`type`,`term`),
959 INDEX `uid_term_tid` (`uid`,`term`,`tid`),
960 INDEX `type_term` (`type`,`term`),
961 INDEX `uid_otype_type_term_global_created` (`uid`,`otype`,`type`,`term`,`global`,`created`),
962 INDEX `otype_type_term_tid` (`otype`,`type`,`term`,`tid`),
963 INDEX `guid` (`guid`)
964 ) DEFAULT CHARSET=utf8;
969 CREATE TABLE IF NOT EXISTS `thread` (
970 `iid` int(10) unsigned NOT NULL DEFAULT 0,
971 `uid` int(10) unsigned NOT NULL DEFAULT 0,
972 `contact-id` int(11) unsigned NOT NULL DEFAULT 0,
973 `gcontact-id` int(11) unsigned NOT NULL DEFAULT 0,
974 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
975 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
976 `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
977 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
978 `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
979 `wall` tinyint(1) NOT NULL DEFAULT 0,
980 `private` tinyint(1) NOT NULL DEFAULT 0,
981 `pubmail` tinyint(1) NOT NULL DEFAULT 0,
982 `moderated` tinyint(1) NOT NULL DEFAULT 0,
983 `visible` tinyint(1) NOT NULL DEFAULT 0,
984 `spam` tinyint(1) NOT NULL DEFAULT 0,
985 `starred` tinyint(1) NOT NULL DEFAULT 0,
986 `ignored` tinyint(1) NOT NULL DEFAULT 0,
987 `bookmark` tinyint(1) NOT NULL DEFAULT 0,
988 `unseen` tinyint(1) NOT NULL DEFAULT 1,
989 `deleted` tinyint(1) NOT NULL DEFAULT 0,
990 `origin` tinyint(1) NOT NULL DEFAULT 0,
991 `forum_mode` tinyint(1) NOT NULL DEFAULT 0,
992 `mention` tinyint(1) NOT NULL DEFAULT 0,
993 `network` varchar(32) NOT NULL DEFAULT '',
995 INDEX `created` (`created`),
996 INDEX `commented` (`commented`),
997 INDEX `uid_network_commented` (`uid`,`network`,`commented`),
998 INDEX `uid_network_created` (`uid`,`network`,`created`),
999 INDEX `uid_contactid_commented` (`uid`,`contact-id`,`commented`),
1000 INDEX `uid_contactid_created` (`uid`,`contact-id`,`created`),
1001 INDEX `uid_gcontactid_commented` (`uid`,`gcontact-id`,`commented`),
1002 INDEX `uid_gcontactid_created` (`uid`,`gcontact-id`,`created`),
1003 INDEX `wall_private_received` (`wall`,`private`,`received`),
1004 INDEX `uid_created` (`uid`,`created`),
1005 INDEX `uid_commented` (`uid`,`commented`)
1006 ) DEFAULT CHARSET=utf8;
1011 CREATE TABLE IF NOT EXISTS `tokens` (
1012 `id` varchar(40) NOT NULL,
1013 `secret` text NOT NULL,
1014 `client_id` varchar(20) NOT NULL DEFAULT '',
1015 `expires` int(11) NOT NULL DEFAULT 0,
1016 `scope` varchar(200) NOT NULL DEFAULT '',
1017 `uid` int(11) NOT NULL DEFAULT 0,
1019 ) DEFAULT CHARSET=utf8;
1024 CREATE TABLE IF NOT EXISTS `user` (
1025 `uid` int(11) NOT NULL auto_increment,
1026 `guid` varchar(64) NOT NULL DEFAULT '',
1027 `username` varchar(255) NOT NULL DEFAULT '',
1028 `password` varchar(255) NOT NULL DEFAULT '',
1029 `nickname` varchar(255) NOT NULL DEFAULT '',
1030 `email` varchar(255) NOT NULL DEFAULT '',
1031 `openid` varchar(255) NOT NULL DEFAULT '',
1032 `timezone` varchar(128) NOT NULL DEFAULT '',
1033 `language` varchar(32) NOT NULL DEFAULT 'en',
1034 `register_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1035 `login_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1036 `default-location` varchar(255) NOT NULL DEFAULT '',
1037 `allow_location` tinyint(1) NOT NULL DEFAULT 0,
1038 `theme` varchar(255) NOT NULL DEFAULT '',
1039 `pubkey` text NOT NULL,
1040 `prvkey` text NOT NULL,
1041 `spubkey` text NOT NULL,
1042 `sprvkey` text NOT NULL,
1043 `verified` tinyint(1) unsigned NOT NULL DEFAULT 0,
1044 `blocked` tinyint(1) unsigned NOT NULL DEFAULT 0,
1045 `blockwall` tinyint(1) unsigned NOT NULL DEFAULT 0,
1046 `hidewall` tinyint(1) unsigned NOT NULL DEFAULT 0,
1047 `blocktags` tinyint(1) unsigned NOT NULL DEFAULT 0,
1048 `unkmail` tinyint(1) NOT NULL DEFAULT 0,
1049 `cntunkmail` int(11) NOT NULL DEFAULT 10,
1050 `notify-flags` int(11) unsigned NOT NULL DEFAULT 65535,
1051 `page-flags` int(11) unsigned NOT NULL DEFAULT 0,
1052 `prvnets` tinyint(1) NOT NULL DEFAULT 0,
1053 `pwdreset` varchar(255) NOT NULL DEFAULT '',
1054 `maxreq` int(11) NOT NULL DEFAULT 10,
1055 `expire` int(11) unsigned NOT NULL DEFAULT 0,
1056 `account_removed` tinyint(1) NOT NULL DEFAULT 0,
1057 `account_expired` tinyint(1) NOT NULL DEFAULT 0,
1058 `account_expires_on` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1059 `expire_notification_sent` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1060 `service_class` varchar(32) NOT NULL DEFAULT '',
1061 `def_gid` int(11) NOT NULL DEFAULT 0,
1062 `allow_cid` mediumtext NOT NULL,
1063 `allow_gid` mediumtext NOT NULL,
1064 `deny_cid` mediumtext NOT NULL,
1065 `deny_gid` mediumtext NOT NULL,
1066 `openidserver` text NOT NULL,
1068 INDEX `nickname` (`nickname`)
1069 ) DEFAULT CHARSET=utf8;
1074 CREATE TABLE IF NOT EXISTS `userd` (
1075 `id` int(11) NOT NULL auto_increment,
1076 `username` varchar(255) NOT NULL,
1078 INDEX `username` (`username`)
1079 ) DEFAULT CHARSET=utf8;
1082 -- TABLE workerqueue
1084 CREATE TABLE IF NOT EXISTS `workerqueue` (
1085 `id` int(11) NOT NULL auto_increment,
1086 `parameter` text NOT NULL,
1087 `priority` tinyint(3) unsigned NOT NULL DEFAULT 0,
1088 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1089 `pid` int(11) NOT NULL DEFAULT 0,
1090 `executed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1092 INDEX `created` (`created`)
1093 ) DEFAULT CHARSET=utf8;