Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 123 lines (105 sloc) 3.795 kb
4e17e6c9 » thomascube
2005-09-25 Initial revision
1 -- RoundCube Webmail initial database structure
ac26b964 » thomascube
2008-03-25 Optimize database schema; get rid of unnecessary indexes
2 -- Version 0.1
4e17e6c9 » thomascube
2005-09-25 Initial revision
3 --
4
5 -- --------------------------------------------------------
6
7 --
8 -- Table structure for table `cache`
9 --
10
11 CREATE TABLE `cache` (
12 `cache_id` int(10) unsigned NOT NULL auto_increment,
13 `user_id` int(10) unsigned NOT NULL default '0',
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
14 `session_id` varchar(40) default NULL,
4e17e6c9 » thomascube
2005-09-25 Initial revision
15 `cache_key` varchar(128) NOT NULL default '',
16 `created` datetime NOT NULL default '0000-00-00 00:00:00',
17 `data` longtext NOT NULL,
18 PRIMARY KEY (`cache_id`),
ac26b964 » thomascube
2008-03-25 Optimize database schema; get rid of unnecessary indexes
19 INDEX `user_cache_index` (`user_id`,`cache_key`)
535da27c » thomascube
2006-02-19 Updated installation instructions
20 );
4e17e6c9 » thomascube
2005-09-25 Initial revision
21
22 -- --------------------------------------------------------
23
24 --
25 -- Table structure for table `contacts`
26 --
27
28 CREATE TABLE `contacts` (
29 `contact_id` int(10) unsigned NOT NULL auto_increment,
30 `user_id` int(10) unsigned NOT NULL default '0',
e447cb07 » thomascube
2005-11-06 Added 'changed' col to contacts table and support for 160-bit session…
31 `changed` datetime NOT NULL default '0000-00-00 00:00:00',
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
32 `del` tinyint(1) NOT NULL default '0',
4e17e6c9 » thomascube
2005-09-25 Initial revision
33 `name` varchar(128) NOT NULL default '',
34 `email` varchar(128) NOT NULL default '',
64009eb8 » thomascube
2006-08-11 Reverted files to r305
35 `firstname` varchar(128) NOT NULL default '',
36 `surname` varchar(128) NOT NULL default '',
4e17e6c9 » thomascube
2005-09-25 Initial revision
37 `vcard` text NOT NULL,
38 PRIMARY KEY (`contact_id`),
39 KEY `user_id` (`user_id`)
535da27c » thomascube
2006-02-19 Updated installation instructions
40 );
4e17e6c9 » thomascube
2005-09-25 Initial revision
41
42 -- --------------------------------------------------------
43
44 --
45 -- Table structure for table `identities`
46 --
47
48 CREATE TABLE `identities` (
49 `identity_id` int(10) unsigned NOT NULL auto_increment,
50 `user_id` int(10) unsigned NOT NULL default '0',
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
51 `del` tinyint(1) NOT NULL default '0',
52 `standard` tinyint(1) NOT NULL default '0',
d7f3d796 » alecpl
2008-05-19 -Fixed Mysql DDL for default identities creation (#1485070)
53 `name` varchar(128) NOT NULL,
4e17e6c9 » thomascube
2005-09-25 Initial revision
54 `organization` varchar(128) NOT NULL default '',
d7f3d796 » alecpl
2008-05-19 -Fixed Mysql DDL for default identities creation (#1485070)
55 `email` varchar(128) NOT NULL,
4e17e6c9 » thomascube
2005-09-25 Initial revision
56 `reply-to` varchar(128) NOT NULL default '',
57 `bcc` varchar(128) NOT NULL default '',
d7f3d796 » alecpl
2008-05-19 -Fixed Mysql DDL for default identities creation (#1485070)
58 `signature` text NOT NULL default '',
a0109c49 » svncommit
2006-09-14 Initial TinyMCE editor support (still need to work on spellcheck and …
59 `html_signature` tinyint(1) NOT NULL default '0',
4e17e6c9 » thomascube
2005-09-25 Initial revision
60 PRIMARY KEY (`identity_id`),
61 KEY `user_id` (`user_id`)
535da27c » thomascube
2006-02-19 Updated installation instructions
62 );
4e17e6c9 » thomascube
2005-09-25 Initial revision
63
64 -- --------------------------------------------------------
65
66 --
67 -- Table structure for table `session`
68 --
69
70 CREATE TABLE `session` (
e0ddd4e6 » thomascube
2005-11-06 Added 'changed' col to contacts table and support for 160-bit session…
71 `sess_id` varchar(40) NOT NULL default '',
4e17e6c9 » thomascube
2005-09-25 Initial revision
72 `created` datetime NOT NULL default '0000-00-00 00:00:00',
73 `changed` datetime NOT NULL default '0000-00-00 00:00:00',
84d06edb » thomascube
2007-09-19 IPv6 Compatability
74 `ip` VARCHAR(40) NOT NULL default '',
4e17e6c9 » thomascube
2005-09-25 Initial revision
75 `vars` text NOT NULL,
76 PRIMARY KEY (`sess_id`)
535da27c » thomascube
2006-02-19 Updated installation instructions
77 );
4e17e6c9 » thomascube
2005-09-25 Initial revision
78
79 -- --------------------------------------------------------
80
81 --
82 -- Table structure for table `users`
83 --
84
85 CREATE TABLE `users` (
86 `user_id` int(10) unsigned NOT NULL auto_increment,
87 `username` varchar(128) NOT NULL default '',
42b11351 » thomascube
2005-10-07 Several bugfixes and feature improvements
88 `mail_host` varchar(128) NOT NULL default '',
89 `alias` varchar(128) NOT NULL default '',
4e17e6c9 » thomascube
2005-09-25 Initial revision
90 `created` datetime NOT NULL default '0000-00-00 00:00:00',
91 `last_login` datetime NOT NULL default '0000-00-00 00:00:00',
92 `language` varchar(5) NOT NULL default 'en',
112bff6f » thomascube
2007-10-10 Set prefs field in user table to null (#1484386)
93 `preferences` text,
6cb77869 » alecpl
2008-04-03 #1484854
94 PRIMARY KEY (`user_id`),
95 INDEX `username_index` (`username`),
96 INDEX `alias_index` (`alias`)
535da27c » thomascube
2006-02-19 Updated installation instructions
97 );
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
98
99 -- --------------------------------------------------------
100
101 --
102 -- Table structure for table `messages`
103 --
104
105 CREATE TABLE `messages` (
106 `message_id` int(11) unsigned NOT NULL auto_increment,
107 `user_id` int(11) unsigned NOT NULL default '0',
108 `del` tinyint(1) NOT NULL default '0',
109 `cache_key` varchar(128) NOT NULL default '',
c6e808e9 » svncommit
2006-01-25 fixed mysql SQL scripts for new created column
110 `created` datetime NOT NULL default '0000-00-00 00:00:00',
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
111 `idx` int(11) unsigned NOT NULL default '0',
112 `uid` int(11) unsigned NOT NULL default '0',
113 `subject` varchar(255) NOT NULL default '',
114 `from` varchar(255) NOT NULL default '',
115 `to` varchar(255) NOT NULL default '',
116 `cc` varchar(255) NOT NULL default '',
117 `date` datetime NOT NULL default '0000-00-00 00:00:00',
118 `size` int(11) unsigned NOT NULL default '0',
119 `headers` text NOT NULL,
f7bfec96 » thomascube
2006-08-25 Finalized new message parsing. Attention: changes in database schema
120 `structure` text,
ac26b964 » thomascube
2008-03-25 Optimize database schema; get rid of unnecessary indexes
121 PRIMARY KEY (`message_id`),
43a42dcf » thomascube
2007-03-18 Use user_id for unique key in messages table (closes #1484074)
122 UNIQUE `uniqueness` (`user_id`, `cache_key`, `uid`)
535da27c » thomascube
2006-02-19 Updated installation instructions
123 );
1cded857 » thomascube
2005-12-03 Re-design of caching (new database table added\!); some bugfixes; Pos…
124
125
Something went wrong with that request. Please try again.