3 -- http://www.phpmyadmin.net
6 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
8 -- --------------------------------------------------------
11 -- Table structure for table `addon`
14 CREATE TABLE IF NOT EXISTS `addon` (
15 `id` int(11) NOT NULL AUTO_INCREMENT,
16 `name` char(255) NOT NULL,
17 `version` char(255) NOT NULL,
18 `installed` tinyint(1) NOT NULL DEFAULT '0',
19 `timestamp` bigint(20) NOT NULL DEFAULT '0',
20 `plugin_admin` tinyint(1) NOT NULL DEFAULT '0',
22 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
24 -- --------------------------------------------------------
27 -- Table structure for table `attach`
30 CREATE TABLE IF NOT EXISTS `attach` (
31 `id` int(11) NOT NULL AUTO_INCREMENT,
32 `uid` int(11) NOT NULL,
33 `hash` char(64) NOT NULL,
34 `filename` char(255) NOT NULL,
35 `filetype` char(64) NOT NULL,
36 `filesize` int(11) NOT NULL,
37 `data` longblob NOT NULL,
38 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
39 `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
40 `allow_cid` mediumtext NOT NULL,
41 `allow_gid` mediumtext NOT NULL,
42 `deny_cid` mediumtext NOT NULL,
43 `deny_gid` mediumtext NOT NULL,
45 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
47 -- --------------------------------------------------------
50 -- Table structure for table `auth_codes`
53 CREATE TABLE IF NOT EXISTS `auth_codes` (
54 `id` varchar(40) NOT NULL,
55 `client_id` varchar(20) NOT NULL,
56 `redirect_uri` varchar(200) NOT NULL,
57 `expires` int(11) NOT NULL,
58 `scope` varchar(250) NOT NULL,
60 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
62 -- --------------------------------------------------------
65 -- Table structure for table `cache`
68 CREATE TABLE IF NOT EXISTS `cache` (
69 `k` char(255) NOT NULL,
71 `updated` datetime NOT NULL,
73 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
75 -- --------------------------------------------------------
78 -- Table structure for table `challenge`
81 CREATE TABLE IF NOT EXISTS `challenge` (
82 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
83 `challenge` char(255) NOT NULL,
84 `dfrn-id` char(255) NOT NULL,
85 `expire` int(11) NOT NULL,
86 `type` char(255) NOT NULL,
87 `last_update` char(255) NOT NULL,
89 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
91 -- --------------------------------------------------------
94 -- Table structure for table `clients`
97 CREATE TABLE IF NOT EXISTS `clients` (
98 `client_id` varchar(20) NOT NULL,
99 `pw` varchar(20) NOT NULL,
100 `redirect_uri` varchar(200) NOT NULL,
103 `uid` int(11) NOT NULL DEFAULT '0',
104 PRIMARY KEY (`client_id`)
105 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
107 -- --------------------------------------------------------
110 -- Table structure for table `config`
113 CREATE TABLE IF NOT EXISTS `config` (
114 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
115 `cat` char(255) CHARACTER SET ascii NOT NULL,
116 `k` char(255) CHARACTER SET ascii NOT NULL,
119 UNIQUE KEY `access` (`cat`,`k`)
120 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
122 -- --------------------------------------------------------
125 -- Table structure for table `contact`
128 CREATE TABLE IF NOT EXISTS `contact` (
129 `id` int(11) NOT NULL AUTO_INCREMENT,
130 `uid` int(11) NOT NULL COMMENT 'owner uid',
131 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
132 `self` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'boolean 1 == info for local UID, primarily name and photo to use in item displays.',
133 `remote_self` tinyint(1) NOT NULL DEFAULT '0',
134 `rel` tinyint(1) NOT NULL DEFAULT '0',
135 `duplex` tinyint(1) NOT NULL DEFAULT '0',
136 `network` char(255) NOT NULL,
137 `name` char(255) NOT NULL,
138 `nick` char(255) NOT NULL,
139 `attag` char(255) NOT NULL,
140 `photo` text NOT NULL COMMENT 'remote photo URL initially until approved',
141 `thumb` text NOT NULL,
142 `micro` text NOT NULL,
143 `site-pubkey` text NOT NULL,
144 `issued-id` char(255) NOT NULL,
145 `dfrn-id` char(255) NOT NULL,
146 `url` char(255) NOT NULL,
147 `nurl` char(255) NOT NULL,
148 `addr` char(255) NOT NULL,
149 `alias` char(255) NOT NULL,
150 `pubkey` text NOT NULL,
151 `prvkey` text NOT NULL,
152 `batch` char(255) NOT NULL,
153 `request` text NOT NULL,
154 `notify` text NOT NULL,
155 `poll` text NOT NULL,
156 `confirm` text NOT NULL,
157 `poco` text NOT NULL,
158 `aes_allow` tinyint(1) NOT NULL DEFAULT '0',
159 `ret-aes` tinyint(1) NOT NULL DEFAULT '0',
160 `usehub` tinyint(1) NOT NULL DEFAULT '0',
161 `subhub` tinyint(1) NOT NULL DEFAULT '0',
162 `hub-verify` char(255) NOT NULL,
163 `last-update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
164 `success_update` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
165 `name-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
166 `uri-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
167 `avatar-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
168 `term-date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
169 `priority` tinyint(3) NOT NULL,
170 `blocked` tinyint(1) NOT NULL DEFAULT '1',
171 `readonly` tinyint(1) NOT NULL DEFAULT '0',
172 `writable` tinyint(1) NOT NULL DEFAULT '0',
173 `forum` tinyint(1) NOT NULL DEFAULT '0',
174 `hidden` tinyint(1) NOT NULL DEFAULT '0',
175 `pending` tinyint(1) NOT NULL DEFAULT '1',
176 `rating` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0-5 reputation, 0 unknown, 1 call police, 5 inscrutable',
177 `reason` text NOT NULL COMMENT 'why a rating was given - will help friends decide to make friends or not',
178 `closeness` tinyint(2) NOT NULL DEFAULT '99',
179 `info` mediumtext NOT NULL,
180 `profile-id` int(11) NOT NULL DEFAULT '0' COMMENT 'which profile to display - 0 is public default',
181 `bdyear` char(4) NOT NULL COMMENT 'birthday notify flag',
186 KEY `issued-id` (`issued-id`),
187 KEY `dfrn-id` (`dfrn-id`),
188 KEY `blocked` (`blocked`),
189 KEY `readonly` (`readonly`),
190 KEY `network` (`network`),
193 KEY `attag` (`attag`),
196 KEY `batch` (`batch`),
198 KEY `pending` (`pending`),
199 KEY `hidden` (`hidden`),
200 KEY `forum` (`forum`)
201 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
203 -- --------------------------------------------------------
206 -- Table structure for table `conv`
209 CREATE TABLE IF NOT EXISTS `conv` (
210 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
211 `guid` char(64) NOT NULL,
212 `recips` mediumtext NOT NULL,
213 `uid` int(11) NOT NULL,
214 `creator` char(255) NOT NULL,
215 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
216 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
217 `subject` mediumtext NOT NULL,
219 KEY `created` (`created`),
220 KEY `updated` (`updated`)
221 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
223 -- --------------------------------------------------------
226 -- Table structure for table `deliverq`
229 CREATE TABLE IF NOT EXISTS `deliverq` (
230 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
231 `cmd` char(32) NOT NULL,
232 `item` int(11) NOT NULL,
233 `contact` int(11) NOT NULL,
235 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
237 -- --------------------------------------------------------
240 -- Table structure for table `event`
243 CREATE TABLE IF NOT EXISTS `event` (
244 `id` int(11) NOT NULL AUTO_INCREMENT,
245 `uid` int(11) NOT NULL,
246 `cid` int(11) NOT NULL,
247 `uri` char(255) NOT NULL,
248 `created` datetime NOT NULL,
249 `edited` datetime NOT NULL,
250 `start` datetime NOT NULL,
251 `finish` datetime NOT NULL,
252 `desc` text NOT NULL,
253 `location` text NOT NULL,
254 `type` char(255) NOT NULL,
255 `nofinish` tinyint(1) NOT NULL DEFAULT '0',
256 `adjust` tinyint(1) NOT NULL DEFAULT '1',
257 `allow_cid` mediumtext NOT NULL,
258 `allow_gid` mediumtext NOT NULL,
259 `deny_cid` mediumtext NOT NULL,
260 `deny_gid` mediumtext NOT NULL,
262 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
264 -- --------------------------------------------------------
267 -- Table structure for table `fcontact`
270 CREATE TABLE IF NOT EXISTS `fcontact` (
271 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
272 `url` char(255) NOT NULL,
273 `name` char(255) NOT NULL,
274 `photo` char(255) NOT NULL,
275 `request` char(255) NOT NULL,
276 `nick` char(255) NOT NULL,
277 `addr` char(255) NOT NULL,
278 `batch` char(255) NOT NULL,
279 `notify` char(255) NOT NULL,
280 `poll` char(255) NOT NULL,
281 `confirm` char(255) NOT NULL,
282 `priority` tinyint(1) NOT NULL,
283 `network` char(32) NOT NULL,
284 `alias` char(255) NOT NULL,
285 `pubkey` text NOT NULL,
286 `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
289 KEY `network` (`network`)
290 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
292 -- --------------------------------------------------------
295 -- Table structure for table `ffinder`
298 CREATE TABLE IF NOT EXISTS `ffinder` (
299 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
300 `uid` int(10) unsigned NOT NULL,
301 `cid` int(10) unsigned NOT NULL,
302 `fid` int(10) unsigned NOT NULL,
304 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
306 -- --------------------------------------------------------
309 -- Table structure for table `fserver`
312 CREATE TABLE IF NOT EXISTS `fserver` (
313 `id` int(11) NOT NULL AUTO_INCREMENT,
314 `server` char(255) NOT NULL,
315 `posturl` char(255) NOT NULL,
318 KEY `server` (`server`)
319 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
321 -- --------------------------------------------------------
324 -- Table structure for table `fsuggest`
327 CREATE TABLE IF NOT EXISTS `fsuggest` (
328 `id` int(11) NOT NULL AUTO_INCREMENT,
329 `uid` int(11) NOT NULL,
330 `cid` int(11) NOT NULL,
331 `name` char(255) NOT NULL,
332 `url` char(255) NOT NULL,
333 `request` char(255) NOT NULL,
334 `photo` char(255) NOT NULL,
335 `note` text NOT NULL,
336 `created` datetime NOT NULL,
338 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
340 -- --------------------------------------------------------
343 -- Table structure for table `gcign`
346 CREATE TABLE IF NOT EXISTS `gcign` (
347 `id` int(11) NOT NULL AUTO_INCREMENT,
348 `uid` int(11) NOT NULL,
349 `gcid` int(11) NOT NULL,
353 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
355 -- --------------------------------------------------------
358 -- Table structure for table `gcontact`
361 CREATE TABLE IF NOT EXISTS `gcontact` (
362 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
363 `name` char(255) NOT NULL,
364 `url` char(255) NOT NULL,
365 `nurl` char(255) NOT NULL,
366 `photo` char(255) NOT NULL,
367 `connect` char(255) NOT NULL,
370 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
372 -- --------------------------------------------------------
375 -- Table structure for table `glink`
378 CREATE TABLE IF NOT EXISTS `glink` (
379 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
380 `cid` int(11) NOT NULL,
381 `uid` int(11) NOT NULL,
382 `gcid` int(11) NOT NULL,
383 `updated` datetime NOT NULL,
388 KEY `updated` (`updated`)
389 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
391 -- --------------------------------------------------------
394 -- Table structure for table `group`
397 CREATE TABLE IF NOT EXISTS `group` (
398 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
399 `uid` int(10) unsigned NOT NULL,
400 `visible` tinyint(1) NOT NULL DEFAULT '0',
401 `deleted` tinyint(1) NOT NULL DEFAULT '0',
402 `name` char(255) NOT NULL,
404 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
406 -- --------------------------------------------------------
409 -- Table structure for table `group_member`
412 CREATE TABLE IF NOT EXISTS `group_member` (
413 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
414 `uid` int(10) unsigned NOT NULL,
415 `gid` int(10) unsigned NOT NULL,
416 `contact-id` int(10) unsigned NOT NULL,
418 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
420 -- --------------------------------------------------------
423 -- Table structure for table `guid`
426 CREATE TABLE IF NOT EXISTS `guid` (
427 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
428 `guid` char(64) NOT NULL,
431 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
433 -- --------------------------------------------------------
436 -- Table structure for table `hook`
439 CREATE TABLE IF NOT EXISTS `hook` (
440 `id` int(11) NOT NULL AUTO_INCREMENT,
441 `hook` char(255) NOT NULL,
442 `file` char(255) NOT NULL,
443 `function` char(255) NOT NULL,
445 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
447 -- --------------------------------------------------------
450 -- Table structure for table `intro`
453 CREATE TABLE IF NOT EXISTS `intro` (
454 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
455 `uid` int(10) unsigned NOT NULL,
456 `fid` int(11) NOT NULL DEFAULT '0',
457 `contact-id` int(11) NOT NULL,
458 `knowyou` tinyint(1) NOT NULL,
459 `duplex` tinyint(1) NOT NULL DEFAULT '0',
460 `note` text NOT NULL,
461 `hash` char(255) NOT NULL,
462 `datetime` datetime NOT NULL,
463 `blocked` tinyint(1) NOT NULL DEFAULT '1',
464 `ignore` tinyint(1) NOT NULL DEFAULT '0',
466 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
468 -- --------------------------------------------------------
471 -- Table structure for table `item`
474 CREATE TABLE IF NOT EXISTS `item` (
475 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
476 `guid` char(64) NOT NULL,
477 `uri` char(255) CHARACTER SET ascii NOT NULL,
478 `uid` int(10) unsigned NOT NULL DEFAULT '0',
479 `contact-id` int(10) unsigned NOT NULL DEFAULT '0',
480 `type` char(255) NOT NULL,
481 `wall` tinyint(1) NOT NULL DEFAULT '0',
482 `gravity` tinyint(1) NOT NULL DEFAULT '0',
483 `parent` int(10) unsigned NOT NULL DEFAULT '0',
484 `parent-uri` char(255) CHARACTER SET ascii NOT NULL,
485 `extid` char(255) NOT NULL,
486 `thr-parent` char(255) NOT NULL,
487 `created` datetime NOT NULL,
488 `edited` datetime NOT NULL,
489 `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
490 `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
491 `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
492 `owner-name` char(255) NOT NULL,
493 `owner-link` char(255) NOT NULL,
494 `owner-avatar` char(255) NOT NULL,
495 `author-name` char(255) NOT NULL,
496 `author-link` char(255) NOT NULL,
497 `author-avatar` char(255) NOT NULL,
498 `title` char(255) NOT NULL,
499 `body` mediumtext NOT NULL,
500 `app` char(255) NOT NULL,
501 `verb` char(255) NOT NULL,
502 `object-type` char(255) NOT NULL,
503 `object` text NOT NULL,
504 `target-type` char(255) NOT NULL,
505 `target` text NOT NULL,
506 `postopts` text NOT NULL,
507 `plink` char(255) NOT NULL,
508 `resource-id` char(255) NOT NULL,
509 `event-id` int(11) NOT NULL,
510 `tag` mediumtext NOT NULL,
511 `attach` mediumtext NOT NULL,
512 `inform` mediumtext NOT NULL,
513 `file` mediumtext NOT NULL,
514 `location` char(255) NOT NULL,
515 `coord` char(255) NOT NULL,
516 `allow_cid` mediumtext NOT NULL,
517 `allow_gid` mediumtext NOT NULL,
518 `deny_cid` mediumtext NOT NULL,
519 `deny_gid` mediumtext NOT NULL,
520 `private` tinyint(1) NOT NULL DEFAULT '0',
521 `pubmail` tinyint(1) NOT NULL DEFAULT '0',
522 `moderated` tinyint(1) NOT NULL DEFAULT '0',
523 `visible` tinyint(1) NOT NULL DEFAULT '0',
524 `spam` tinyint(1) NOT NULL DEFAULT '0',
525 `starred` tinyint(1) NOT NULL DEFAULT '0',
526 `bookmark` tinyint(1) NOT NULL DEFAULT '0',
527 `unseen` tinyint(1) NOT NULL DEFAULT '1',
528 `deleted` tinyint(1) NOT NULL DEFAULT '0',
529 `origin` tinyint(1) NOT NULL DEFAULT '0',
530 `forum_mode` tinyint(1) NOT NULL DEFAULT '0',
531 `last-child` tinyint(1) unsigned NOT NULL DEFAULT '1',
535 KEY `contact-id` (`contact-id`),
537 KEY `parent` (`parent`),
538 KEY `parent-uri` (`parent-uri`),
539 KEY `created` (`created`),
540 KEY `edited` (`edited`),
541 KEY `visible` (`visible`),
542 KEY `deleted` (`deleted`),
543 KEY `last-child` (`last-child`),
544 KEY `unseen` (`unseen`),
545 KEY `extid` (`extid`),
546 KEY `received` (`received`),
547 KEY `starred` (`starred`),
549 KEY `origin` (`origin`),
551 KEY `forum_mode` (`forum_mode`),
552 KEY `author-link` (`author-link`),
553 KEY `bookmark` (`bookmark`),
554 KEY `moderated` (`moderated`),
556 KEY `author-name` (`author-name`),
557 FULLTEXT KEY `title` (`title`),
558 FULLTEXT KEY `body` (`body`),
559 FULLTEXT KEY `allow_cid` (`allow_cid`),
560 FULLTEXT KEY `allow_gid` (`allow_gid`),
561 FULLTEXT KEY `deny_cid` (`deny_cid`),
562 FULLTEXT KEY `deny_gid` (`deny_gid`),
563 FULLTEXT KEY `tag` (`tag`),
564 FULLTEXT KEY `file` (`file`)
565 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
567 -- --------------------------------------------------------
570 -- Table structure for table `item_id`
573 CREATE TABLE IF NOT EXISTS `item_id` (
574 `iid` int(11) NOT NULL,
575 `uid` int(11) NOT NULL,
576 `sid` char(255) NOT NULL,
577 `service` char(255) NOT NULL,
581 KEY `service` (`service`)
582 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
584 -- --------------------------------------------------------
587 -- Table structure for table `mail`
590 CREATE TABLE IF NOT EXISTS `mail` (
591 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
592 `uid` int(10) unsigned NOT NULL,
593 `guid` char(64) NOT NULL,
594 `from-name` char(255) NOT NULL,
595 `from-photo` char(255) NOT NULL,
596 `from-url` char(255) NOT NULL,
597 `contact-id` char(255) NOT NULL,
598 `convid` int(11) NOT NULL,
599 `title` char(255) NOT NULL,
600 `body` mediumtext NOT NULL,
601 `seen` tinyint(1) NOT NULL,
602 `reply` tinyint(1) NOT NULL DEFAULT '0',
603 `replied` tinyint(1) NOT NULL,
604 `unknown` tinyint(1) NOT NULL DEFAULT '0',
605 `uri` char(255) NOT NULL,
606 `parent-uri` char(255) NOT NULL,
607 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
609 KEY `reply` (`reply`),
614 KEY `parent-uri` (`parent-uri`),
615 KEY `created` (`created`),
616 KEY `convid` (`convid`),
617 KEY `unknown` (`unknown`)
618 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
620 -- --------------------------------------------------------
623 -- Table structure for table `mailacct`
626 CREATE TABLE IF NOT EXISTS `mailacct` (
627 `id` int(11) NOT NULL AUTO_INCREMENT,
628 `uid` int(11) NOT NULL,
629 `server` char(255) NOT NULL,
630 `port` int(11) NOT NULL,
631 `ssltype` char(16) NOT NULL,
632 `mailbox` char(255) NOT NULL,
633 `user` char(255) NOT NULL,
634 `pass` text NOT NULL,
635 `action` int(11) NOT NULL,
636 `movetofolder` char(255) NOT NULL,
637 `reply_to` char(255) NOT NULL,
638 `pubmail` tinyint(1) NOT NULL DEFAULT '0',
639 `last_check` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
641 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
643 -- --------------------------------------------------------
646 -- Table structure for table `manage`
649 CREATE TABLE IF NOT EXISTS `manage` (
650 `id` int(11) NOT NULL AUTO_INCREMENT,
651 `uid` int(11) NOT NULL,
652 `mid` int(11) NOT NULL,
656 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
658 -- --------------------------------------------------------
661 -- Table structure for table `notify`
664 CREATE TABLE IF NOT EXISTS `notify` (
665 `id` int(11) NOT NULL AUTO_INCREMENT,
666 `hash` char(64) NOT NULL,
667 `name` char(255) NOT NULL,
668 `url` char(255) NOT NULL,
669 `photo` char(255) NOT NULL,
670 `date` datetime NOT NULL,
671 `msg` mediumtext NOT NULL,
672 `uid` int(11) NOT NULL,
673 `link` char(255) NOT NULL,
674 `parent` int(11) NOT NULL,
675 `seen` tinyint(1) NOT NULL DEFAULT '0',
676 `type` int(11) NOT NULL,
677 `verb` char(255) NOT NULL,
678 `otype` char(16) NOT NULL,
685 KEY `parent` (`parent`),
687 KEY `otype` (`otype`)
688 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
690 -- --------------------------------------------------------
693 -- Table structure for table `notify-threads`
696 CREATE TABLE IF NOT EXISTS `notify-threads` (
697 `id` int(11) NOT NULL AUTO_INCREMENT,
698 `notify-id` int(11) NOT NULL,
699 `master-parent-item` int(10) unsigned NOT NULL DEFAULT '0',
700 `parent-item` int(10) unsigned NOT NULL DEFAULT '0',
701 `receiver-uid` int(11) NOT NULL,
703 KEY `master-parent-item` (`master-parent-item`),
704 KEY `receiver-uid` (`receiver-uid`)
705 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
707 -- --------------------------------------------------------
710 -- Table structure for table `pconfig`
713 CREATE TABLE IF NOT EXISTS `pconfig` (
714 `id` int(11) NOT NULL AUTO_INCREMENT,
715 `uid` int(11) NOT NULL DEFAULT '0',
716 `cat` char(255) CHARACTER SET ascii NOT NULL,
717 `k` char(255) CHARACTER SET ascii NOT NULL,
718 `v` mediumtext NOT NULL,
720 UNIQUE KEY `access` (`uid`,`cat`,`k`)
721 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
723 -- --------------------------------------------------------
726 -- Table structure for table `photo`
729 CREATE TABLE IF NOT EXISTS `photo` (
730 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
731 `uid` int(10) unsigned NOT NULL,
732 `contact-id` int(10) unsigned NOT NULL DEFAULT '0',
733 `guid` char(64) NOT NULL,
734 `resource-id` char(255) NOT NULL,
735 `created` datetime NOT NULL,
736 `edited` datetime NOT NULL,
737 `title` char(255) NOT NULL,
738 `desc` text NOT NULL,
739 `album` char(255) NOT NULL,
740 `filename` char(255) NOT NULL,
741 `height` smallint(6) NOT NULL,
742 `width` smallint(6) NOT NULL,
743 `data` mediumblob NOT NULL,
744 `scale` tinyint(3) NOT NULL,
745 `profile` tinyint(1) NOT NULL DEFAULT '0',
746 `allow_cid` mediumtext NOT NULL,
747 `allow_gid` mediumtext NOT NULL,
748 `deny_cid` mediumtext NOT NULL,
749 `deny_gid` mediumtext NOT NULL,
752 KEY `resource-id` (`resource-id`),
753 KEY `album` (`album`),
754 KEY `scale` (`scale`),
755 KEY `profile` (`profile`)
756 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
758 -- --------------------------------------------------------
761 -- Table structure for table `poll`
764 CREATE TABLE IF NOT EXISTS `poll` (
765 `id` int(11) NOT NULL AUTO_INCREMENT,
766 `uid` int(11) NOT NULL,
767 `q0` mediumtext NOT NULL,
768 `q1` mediumtext NOT NULL,
769 `q2` mediumtext NOT NULL,
770 `q3` mediumtext NOT NULL,
771 `q4` mediumtext NOT NULL,
772 `q5` mediumtext NOT NULL,
773 `q6` mediumtext NOT NULL,
774 `q7` mediumtext NOT NULL,
775 `q8` mediumtext NOT NULL,
776 `q9` mediumtext NOT NULL,
779 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
781 -- --------------------------------------------------------
784 -- Table structure for table `poll_result`
787 CREATE TABLE IF NOT EXISTS `poll_result` (
788 `id` int(11) NOT NULL AUTO_INCREMENT,
789 `poll_id` int(11) NOT NULL,
790 `choice` int(11) NOT NULL,
792 KEY `poll_id` (`poll_id`),
793 KEY `choice` (`choice`)
794 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
796 -- --------------------------------------------------------
799 -- Table structure for table `profile`
802 CREATE TABLE IF NOT EXISTS `profile` (
803 `id` int(11) NOT NULL AUTO_INCREMENT,
804 `uid` int(11) NOT NULL,
805 `profile-name` char(255) NOT NULL,
806 `is-default` tinyint(1) NOT NULL DEFAULT '0',
807 `hide-friends` tinyint(1) NOT NULL DEFAULT '0',
808 `name` char(255) NOT NULL,
809 `pdesc` char(255) NOT NULL,
810 `dob` char(32) NOT NULL DEFAULT '0000-00-00',
811 `address` char(255) NOT NULL,
812 `locality` char(255) NOT NULL,
813 `region` char(255) NOT NULL,
814 `postal-code` char(32) NOT NULL,
815 `country-name` char(255) NOT NULL,
816 `gender` char(32) NOT NULL,
817 `marital` char(255) NOT NULL,
818 `with` text NOT NULL,
819 `sexual` char(255) NOT NULL,
820 `politic` char(255) NOT NULL,
821 `religion` char(255) NOT NULL,
822 `pub_keywords` text NOT NULL,
823 `prv_keywords` text NOT NULL,
824 `about` text NOT NULL,
825 `summary` char(255) NOT NULL,
826 `music` text NOT NULL,
827 `book` text NOT NULL,
829 `film` text NOT NULL,
830 `interest` text NOT NULL,
831 `romance` text NOT NULL,
832 `work` text NOT NULL,
833 `education` text NOT NULL,
834 `contact` text NOT NULL,
835 `homepage` char(255) NOT NULL,
836 `photo` char(255) NOT NULL,
837 `thumb` char(255) NOT NULL,
838 `publish` tinyint(1) NOT NULL DEFAULT '0',
839 `net-publish` tinyint(1) NOT NULL DEFAULT '0',
841 FULLTEXT KEY `pub_keywords` (`pub_keywords`),
842 FULLTEXT KEY `prv_keywords` (`prv_keywords`)
843 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
845 -- --------------------------------------------------------
848 -- Table structure for table `profile_check`
851 CREATE TABLE IF NOT EXISTS `profile_check` (
852 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
853 `uid` int(10) unsigned NOT NULL,
854 `cid` int(10) unsigned NOT NULL DEFAULT '0',
855 `dfrn_id` char(255) NOT NULL,
856 `sec` char(255) NOT NULL,
857 `expire` int(11) NOT NULL,
859 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
861 -- --------------------------------------------------------
864 -- Table structure for table `queue`
867 CREATE TABLE IF NOT EXISTS `queue` (
868 `id` int(11) NOT NULL AUTO_INCREMENT,
869 `cid` int(11) NOT NULL,
870 `network` char(32) NOT NULL,
871 `created` datetime NOT NULL,
872 `last` datetime NOT NULL,
873 `content` mediumtext NOT NULL,
874 `batch` tinyint(1) NOT NULL DEFAULT '0',
877 KEY `network` (`network`),
878 KEY `created` (`created`),
880 KEY `batch` (`batch`)
881 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
883 -- --------------------------------------------------------
886 -- Table structure for table `register`
889 CREATE TABLE IF NOT EXISTS `register` (
890 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
891 `hash` char(255) NOT NULL,
892 `created` datetime NOT NULL,
893 `uid` int(10) unsigned NOT NULL,
894 `password` char(255) NOT NULL,
895 `language` char(16) NOT NULL,
897 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
899 -- --------------------------------------------------------
902 -- Table structure for table `search`
905 CREATE TABLE IF NOT EXISTS `search` (
906 `id` int(11) NOT NULL AUTO_INCREMENT,
907 `uid` int(11) NOT NULL,
908 `term` char(255) NOT NULL,
912 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
914 -- --------------------------------------------------------
917 -- Table structure for table `session`
920 CREATE TABLE IF NOT EXISTS `session` (
921 `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
922 `sid` char(255) NOT NULL,
923 `data` text NOT NULL,
924 `expire` int(10) unsigned NOT NULL,
927 KEY `expire` (`expire`)
928 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
930 -- --------------------------------------------------------
933 -- Table structure for table `sign`
936 CREATE TABLE IF NOT EXISTS `sign` (
937 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
938 `iid` int(10) unsigned NOT NULL,
939 `signed_text` mediumtext NOT NULL,
940 `signature` text NOT NULL,
941 `signer` char(255) NOT NULL,
944 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
946 -- --------------------------------------------------------
949 -- Table structure for table `spam`
952 CREATE TABLE IF NOT EXISTS `spam` (
953 `id` int(11) NOT NULL AUTO_INCREMENT,
954 `uid` int(11) NOT NULL,
955 `spam` int(11) NOT NULL DEFAULT '0',
956 `ham` int(11) NOT NULL DEFAULT '0',
957 `term` char(255) NOT NULL,
958 `date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
964 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
966 -- --------------------------------------------------------
969 -- Table structure for table `tokens`
972 CREATE TABLE IF NOT EXISTS `tokens` (
973 `id` varchar(40) NOT NULL,
974 `secret` text NOT NULL,
975 `client_id` varchar(20) NOT NULL,
976 `expires` int(11) NOT NULL,
977 `scope` varchar(200) NOT NULL,
978 `uid` int(11) NOT NULL,
980 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
982 -- --------------------------------------------------------
985 -- Table structure for table `user`
988 CREATE TABLE IF NOT EXISTS `user` (
989 `uid` int(11) NOT NULL AUTO_INCREMENT,
990 `guid` char(16) NOT NULL,
991 `username` char(255) NOT NULL,
992 `password` char(255) NOT NULL,
993 `nickname` char(255) NOT NULL,
994 `email` char(255) NOT NULL,
995 `openid` char(255) NOT NULL,
996 `timezone` char(128) NOT NULL,
997 `language` char(16) NOT NULL DEFAULT 'en',
998 `register_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
999 `login_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1000 `default-location` char(255) NOT NULL,
1001 `allow_location` tinyint(1) NOT NULL DEFAULT '0',
1002 `theme` char(255) NOT NULL,
1003 `pubkey` text NOT NULL,
1004 `prvkey` text NOT NULL,
1005 `spubkey` text NOT NULL,
1006 `sprvkey` text NOT NULL,
1007 `verified` tinyint(1) unsigned NOT NULL DEFAULT '0',
1008 `blocked` tinyint(1) unsigned NOT NULL DEFAULT '0',
1009 `blockwall` tinyint(1) NOT NULL DEFAULT '0',
1010 `hidewall` tinyint(1) NOT NULL DEFAULT '0',
1011 `blocktags` tinyint(1) NOT NULL DEFAULT '0',
1012 `unkmail` tinyint(1) NOT NULL DEFAULT '0',
1013 `cntunkmail` int(11) NOT NULL DEFAULT '10',
1014 `notify-flags` int(11) unsigned NOT NULL DEFAULT '65535',
1015 `page-flags` int(11) NOT NULL DEFAULT '0',
1016 `prvnets` tinyint(1) NOT NULL DEFAULT '0',
1017 `pwdreset` char(255) NOT NULL,
1018 `maxreq` int(11) NOT NULL DEFAULT '10',
1019 `expire` int(10) unsigned NOT NULL DEFAULT '0',
1020 `account_expired` tinyint(1) NOT NULL DEFAULT '0',
1021 `account_expires_on` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1022 `expire_notification_sent` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
1023 `allow_cid` mediumtext NOT NULL,
1024 `allow_gid` mediumtext NOT NULL,
1025 `deny_cid` mediumtext NOT NULL,
1026 `deny_gid` mediumtext NOT NULL,
1027 `openidserver` text NOT NULL,
1028 PRIMARY KEY (`uid`),
1029 KEY `nickname` (`nickname`),
1030 KEY `login_date` (`login_date`),
1031 KEY `account_expired` (`account_expired`),
1032 KEY `hidewall` (`hidewall`),
1033 KEY `blockwall` (`blockwall`),
1034 KEY `blocked` (`blocked`),
1035 KEY `verified` (`verified`),
1036 KEY `unkmail` (`unkmail`),
1037 KEY `cntunkmail` (`cntunkmail`)
1038 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
1040 -- --------------------------------------------------------
1043 -- Table structure for table `userd`
1046 CREATE TABLE IF NOT EXISTS `userd` (
1047 `id` int(11) NOT NULL AUTO_INCREMENT,
1048 `username` char(255) NOT NULL,
1050 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;