3 -- http://www.phpmyadmin.net
5 -- Generation Time: Jul 02, 2010 at 05:22 PM
6 -- Server version: 5.1.39
9 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
12 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
13 /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
14 /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
15 /*!40101 SET NAMES utf8 */;
18 -- --------------------------------------------------------
21 -- Table structure for table `contact`
24 CREATE TABLE IF NOT EXISTS `contact` (
25 `id` int(11) NOT NULL AUTO_INCREMENT,
26 `uid` int(11) NOT NULL COMMENT 'owner uid',
27 `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
28 `self` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'boolean 1 == info for local UID, primarily name and photo to use in item displays.',
29 `name` char(255) NOT NULL,
30 `photo` text NOT NULL COMMENT 'remote photo URL initially until approved',
31 `thumb` text NOT NULL,
32 `site-pubkey` text NOT NULL,
33 `issued-id` char(255) NOT NULL,
34 `dfrn-id` char(255) NOT NULL,
35 `url` char(255) NOT NULL,
36 `pubkey` text NOT NULL,
37 `prvkey` text NOT NULL,
38 `request` text NOT NULL,
39 `notify` text NOT NULL,
41 `confirm` text NOT NULL,
42 `aes_allow` tinyint(1) NOT NULL DEFAULT '0',
43 `ret-id` char(255) NOT NULL,
44 `ret-pubkey` text NOT NULL,
45 `priority` tinyint(3) NOT NULL,
46 `blocked` tinyint(1) NOT NULL DEFAULT '1',
47 `visible` tinyint(1) NOT NULL DEFAULT '0',
48 `rating` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0-5 reputation, 0 unknown, 1 call police, 5 inscrutable',
49 `reason` text NOT NULL COMMENT 'why a rating was given - will help friends decide to make friends or not',
50 `profile-id` int(11) NOT NULL DEFAULT '0' COMMENT 'which profile to display - 0 is public default',
52 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=100 ;
54 -- --------------------------------------------------------
57 -- Table structure for table `group`
60 CREATE TABLE IF NOT EXISTS `group` (
61 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
62 `uid` int(10) unsigned NOT NULL,
63 `name` char(255) NOT NULL,
65 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
67 -- --------------------------------------------------------
70 -- Table structure for table `group_member`
73 CREATE TABLE IF NOT EXISTS `group_member` (
74 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
75 `uid` int(10) unsigned NOT NULL,
76 `gid` int(10) unsigned NOT NULL,
77 `contact-id` int(10) unsigned NOT NULL,
79 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
81 -- --------------------------------------------------------
84 -- Table structure for table `intro`
87 CREATE TABLE IF NOT EXISTS `intro` (
88 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
89 `uid` int(10) unsigned NOT NULL,
90 `contact-id` int(11) NOT NULL,
91 `knowyou` tinyint(1) NOT NULL,
93 `hash` char(255) NOT NULL,
94 `datetime` datetime NOT NULL,
95 `blocked` tinyint(1) NOT NULL DEFAULT '1',
96 `ignore` tinyint(1) NOT NULL DEFAULT '0',
98 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=59 ;
100 -- --------------------------------------------------------
103 -- Table structure for table `item`
106 CREATE TABLE IF NOT EXISTS `item` (
107 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
108 `uid` int(10) unsigned NOT NULL DEFAULT '0',
109 `type` char(255) NOT NULL,
110 `resource-id` char(255) NOT NULL,
111 `contact-id` int(10) unsigned NOT NULL DEFAULT '0',
112 `created` datetime NOT NULL,
113 `edited` datetime NOT NULL,
114 `commented` datetime NOT NULL,
115 `hash` char(255) NOT NULL,
116 `parent` int(10) unsigned NOT NULL DEFAULT '0',
117 `title` char(255) NOT NULL,
118 `body` text NOT NULL,
119 `visible` tinyint(1) NOT NULL DEFAULT '0',
120 `allow_uid` mediumtext NOT NULL,
121 `allow_gid` mediumtext NOT NULL,
122 `deny_uid` mediumtext NOT NULL,
123 `deny_gid` mediumtext NOT NULL,
125 KEY `created` (`created`),
128 KEY `commented` (`commented`),
129 FULLTEXT KEY `body` (`body`),
130 FULLTEXT KEY `title` (`title`)
131 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=15 ;
133 -- --------------------------------------------------------
136 -- Table structure for table `photo`
139 CREATE TABLE IF NOT EXISTS `photo` (
140 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
141 `uid` int(10) unsigned NOT NULL,
142 `resource-id` char(255) NOT NULL,
143 `created` datetime NOT NULL,
144 `edited` datetime NOT NULL,
145 `title` char(255) NOT NULL,
146 `desc` text NOT NULL,
147 `filename` char(255) NOT NULL,
148 `height` smallint(6) NOT NULL,
149 `width` smallint(6) NOT NULL,
150 `data` mediumblob NOT NULL,
151 `scale` tinyint(3) NOT NULL,
152 `allow_uid` mediumtext NOT NULL,
153 `allow_gid` mediumtext NOT NULL,
154 `deny_uid` mediumtext NOT NULL,
155 `deny_gid` mediumtext NOT NULL,
157 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=83 ;
159 -- --------------------------------------------------------
162 -- Table structure for table `profile`
165 CREATE TABLE IF NOT EXISTS `profile` (
166 `id` int(11) NOT NULL AUTO_INCREMENT,
167 `uid` int(11) NOT NULL,
168 `profile-name` char(255) NOT NULL,
169 `is-default` tinyint(1) NOT NULL DEFAULT '0',
170 `name` char(255) NOT NULL,
171 `dob` char(32) NOT NULL,
172 `address` char(255) NOT NULL,
173 `locality` char(255) NOT NULL,
174 `region` char(255) NOT NULL,
175 `postal-code` char(32) NOT NULL,
176 `country-name` char(255) NOT NULL,
177 `age` tinyint(3) NOT NULL,
178 `gender` char(8) NOT NULL,
179 `marital` char(255) NOT NULL,
180 `about` text NOT NULL,
181 `homepage` char(255) NOT NULL,
182 `photo` char(255) NOT NULL,
183 `thumb` char(255) NOT NULL,
184 `publish` tinyint(1) NOT NULL DEFAULT '0',
186 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=16 ;
188 -- --------------------------------------------------------
191 -- Table structure for table `profile_check`
194 CREATE TABLE IF NOT EXISTS `profile_check` (
195 `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
196 `uid` int(10) unsigned NOT NULL,
197 `dfrn_id` char(255) NOT NULL,
198 `expire` int(11) NOT NULL,
200 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=16 ;
202 -- --------------------------------------------------------
205 -- Table structure for table `session`
208 CREATE TABLE IF NOT EXISTS `session` (
209 `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
210 `sid` char(255) NOT NULL,
211 `data` text NOT NULL,
212 `expire` int(10) unsigned NOT NULL,
215 KEY `expire` (`expire`)
216 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=23 ;
218 -- --------------------------------------------------------
221 -- Table structure for table `user`
224 CREATE TABLE IF NOT EXISTS `user` (
225 `uid` int(11) NOT NULL AUTO_INCREMENT,
226 `username` char(255) NOT NULL,
227 `password` char(255) NOT NULL,
228 `nickname` char(255) NOT NULL,
229 `email` char(255) NOT NULL,
230 `timezone` char(128) NOT NULL,
231 `pubkey` text NOT NULL,
232 `prvkey` text NOT NULL,
233 `verified` tinyint(1) unsigned NOT NULL DEFAULT '0',
234 `blocked` tinyint(1) unsigned NOT NULL DEFAULT '0',
236 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=8 ;