diff options
author | Mike Crute <mcrute@gmail.com> | 2011-02-22 22:10:21 -0500 |
---|---|---|
committer | Mike Crute <mcrute@gmail.com> | 2011-02-22 22:10:21 -0500 |
commit | f4727f9d26745a6432286a668236a1eb7cb20cad (patch) | |
tree | 890d621c455539305d544f7276a002681f99f57a /schema | |
download | vim-site-f4727f9d26745a6432286a668236a1eb7cb20cad.tar.bz2 vim-site-f4727f9d26745a6432286a668236a1eb7cb20cad.tar.xz vim-site-f4727f9d26745a6432286a668236a1eb7cb20cad.zip |
Initial import of webroot and schema
Diffstat (limited to 'schema')
-rw-r--r-- | schema/schema-20110223.sql | 183 |
1 files changed, 183 insertions, 0 deletions
diff --git a/schema/schema-20110223.sql b/schema/schema-20110223.sql new file mode 100644 index 0000000..6327e6b --- /dev/null +++ b/schema/schema-20110223.sql | |||
@@ -0,0 +1,183 @@ | |||
1 | CREATE DATABASE IF NOT EXISTS `v8_voprimary` DEFAULT CHARACTER SET latin1; | ||
2 | |||
3 | USE `v8_voprimary`; | ||
4 | |||
5 | DROP TABLE IF EXISTS `vd_donations`; | ||
6 | CREATE TABLE `vd_donations` ( | ||
7 | `mailed_key` varchar(20) DEFAULT NULL, | ||
8 | `amount` int(11) DEFAULT NULL, | ||
9 | `created` date DEFAULT NULL, | ||
10 | `user_id` int(11) DEFAULT NULL | ||
11 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
12 | |||
13 | DROP TABLE IF EXISTS `vd_features`; | ||
14 | CREATE TABLE `vd_features` ( | ||
15 | `feature_id` varchar(15) DEFAULT NULL, | ||
16 | `sort_id` varchar(15) DEFAULT NULL, | ||
17 | `description` varchar(100) DEFAULT NULL | ||
18 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
19 | |||
20 | DROP TABLE IF EXISTS `vd_votes`; | ||
21 | CREATE TABLE `vd_votes` ( | ||
22 | `user_id` int(11) DEFAULT NULL, | ||
23 | `vote_nr` int(11) DEFAULT NULL, | ||
24 | `points` int(11) DEFAULT NULL, | ||
25 | `feature_id` varchar(15) DEFAULT NULL, | ||
26 | `expire_date` date DEFAULT NULL | ||
27 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
28 | |||
29 | DROP TABLE IF EXISTS `vo_news_items`; | ||
30 | CREATE TABLE `vo_news_items` ( | ||
31 | `news_item_id` int(11) NOT NULL AUTO_INCREMENT, | ||
32 | `title` varchar(80) DEFAULT NULL, | ||
33 | `news` mediumtext, | ||
34 | `created_by` int(11) DEFAULT NULL, | ||
35 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
36 | PRIMARY KEY (`news_item_id`) | ||
37 | ) ENGINE=MyISAM AUTO_INCREMENT=100 DEFAULT CHARSET=latin1; | ||
38 | |||
39 | DROP TABLE IF EXISTS `vs_script_downloads`; | ||
40 | CREATE TABLE `vs_script_downloads` ( | ||
41 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
42 | `script_id` int(11) DEFAULT NULL, | ||
43 | `ip` varchar(255) DEFAULT NULL, | ||
44 | KEY `vssd_id_ip` (`script_id`,`ip`) | ||
45 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
46 | |||
47 | DROP TABLE IF EXISTS `vs_script_ratings`; | ||
48 | CREATE TABLE `vs_script_ratings` ( | ||
49 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
50 | `script_id` int(11) DEFAULT NULL, | ||
51 | `rating` int(11) DEFAULT NULL, | ||
52 | `ip` varchar(255) DEFAULT NULL | ||
53 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
54 | |||
55 | DROP TABLE IF EXISTS `vs_script_source`; | ||
56 | CREATE TABLE `vs_script_source` ( | ||
57 | `script_source_id` int(11) NOT NULL AUTO_INCREMENT, | ||
58 | `mime_type` varchar(40) DEFAULT NULL, | ||
59 | `script_id` int(11) DEFAULT NULL, | ||
60 | `vim_version` varchar(10) DEFAULT NULL, | ||
61 | `script_version` varchar(10) DEFAULT NULL, | ||
62 | `version_comment` mediumtext, | ||
63 | `src` longblob, | ||
64 | `created_by` int(11) DEFAULT NULL, | ||
65 | `creation_date` datetime DEFAULT NULL, | ||
66 | `package` varchar(100) DEFAULT NULL, | ||
67 | PRIMARY KEY (`script_source_id`), | ||
68 | KEY `source_date` (`creation_date`), | ||
69 | KEY `vss_sid_creator` (`script_id`,`created_by`) | ||
70 | ) ENGINE=MyISAM AUTO_INCREMENT=15092 DEFAULT CHARSET=latin1; | ||
71 | |||
72 | DROP TABLE IF EXISTS `vs_scripts`; | ||
73 | CREATE TABLE `vs_scripts` ( | ||
74 | `script_id` int(11) NOT NULL AUTO_INCREMENT, | ||
75 | `script_name` varchar(40) DEFAULT NULL, | ||
76 | `script_type` varchar(40) DEFAULT NULL, | ||
77 | `summary` varchar(80) DEFAULT NULL, | ||
78 | `description` longtext, | ||
79 | `install_details` mediumtext, | ||
80 | `ratings` int(11) DEFAULT NULL, | ||
81 | `rating_score` int(11) DEFAULT NULL, | ||
82 | `downloads` int(11) DEFAULT NULL, | ||
83 | `last_updated_by` int(11) DEFAULT NULL, | ||
84 | `last_update_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
85 | `created_by` int(11) DEFAULT NULL, | ||
86 | `creation_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
87 | PRIMARY KEY (`script_id`), | ||
88 | FULLTEXT KEY `summary` (`summary`,`description`,`install_details`) | ||
89 | ) ENGINE=MyISAM AUTO_INCREMENT=3465 DEFAULT CHARSET=latin1; | ||
90 | |||
91 | DROP TABLE IF EXISTS `vs_sessions`; | ||
92 | CREATE TABLE `vs_sessions` ( | ||
93 | `session_id` varchar(32) NOT NULL DEFAULT '', | ||
94 | `user_id` int(11) DEFAULT NULL, | ||
95 | `remote_address` varchar(200) DEFAULT NULL, | ||
96 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
97 | PRIMARY KEY (`session_id`) | ||
98 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
99 | |||
100 | DROP TABLE IF EXISTS `vs_users`; | ||
101 | CREATE TABLE `vs_users` ( | ||
102 | `user_id` int(11) NOT NULL AUTO_INCREMENT, | ||
103 | `user_name` varchar(40) DEFAULT NULL, | ||
104 | `password` varchar(32) DEFAULT NULL, | ||
105 | `first_name` varchar(40) DEFAULT NULL, | ||
106 | `last_name` varchar(40) DEFAULT NULL, | ||
107 | `email` varchar(200) DEFAULT NULL, | ||
108 | `access` int(11) DEFAULT NULL, | ||
109 | `homepage` varchar(255) DEFAULT NULL, | ||
110 | `sponsor_amount` int(11) DEFAULT NULL, | ||
111 | `sponsor_vote_amount` int(11) DEFAULT NULL, | ||
112 | `sponsor_vote_date` date DEFAULT NULL, | ||
113 | `sponsor_flags` int(11) DEFAULT NULL, | ||
114 | PRIMARY KEY (`user_id`) | ||
115 | ) ENGINE=MyISAM AUTO_INCREMENT=27147 DEFAULT CHARSET=latin1; | ||
116 | |||
117 | DROP TABLE IF EXISTS `vt_tip_note_spam`; | ||
118 | CREATE TABLE `vt_tip_note_spam` ( | ||
119 | `tip_spam_note_id` int(11) NOT NULL AUTO_INCREMENT, | ||
120 | `moderated_by` int(11) NOT NULL DEFAULT '0', | ||
121 | `moderated_on` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
122 | `tip_note_id` int(11) NOT NULL DEFAULT '0', | ||
123 | `tip_id` int(11) NOT NULL DEFAULT '0', | ||
124 | `note` longtext NOT NULL, | ||
125 | `created_by` varchar(40) NOT NULL DEFAULT '', | ||
126 | `created_by_email` varchar(100) NOT NULL DEFAULT '', | ||
127 | `last_update_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
128 | `creation_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
129 | `last_updated_by_email` varchar(100) NOT NULL DEFAULT '', | ||
130 | PRIMARY KEY (`tip_spam_note_id`) | ||
131 | ) ENGINE=MyISAM AUTO_INCREMENT=4795 DEFAULT CHARSET=latin1; | ||
132 | |||
133 | DROP TABLE IF EXISTS `vt_tip_notes`; | ||
134 | CREATE TABLE `vt_tip_notes` ( | ||
135 | `tip_note_id` int(11) NOT NULL AUTO_INCREMENT, | ||
136 | `tip_id` int(11) DEFAULT NULL, | ||
137 | `note` longtext, | ||
138 | `last_updated_by_email` varchar(100) DEFAULT NULL, | ||
139 | `last_update_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
140 | `created_by` varchar(40) DEFAULT NULL, | ||
141 | `created_by_email` varchar(100) DEFAULT NULL, | ||
142 | `creation_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
143 | PRIMARY KEY (`tip_note_id`) | ||
144 | ) ENGINE=MyISAM AUTO_INCREMENT=12968 DEFAULT CHARSET=latin1; | ||
145 | |||
146 | DROP TABLE IF EXISTS `vt_tip_ratings`; | ||
147 | CREATE TABLE `vt_tip_ratings` ( | ||
148 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
149 | `tip_id` int(11) DEFAULT NULL, | ||
150 | `rating` int(11) DEFAULT NULL, | ||
151 | `ip` varchar(255) DEFAULT NULL, | ||
152 | KEY `vt_tip_ratings_n1` (`ip`), | ||
153 | KEY `vt_tip_ratings_n2` (`tip_id`) | ||
154 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||
155 | |||
156 | DROP TABLE IF EXISTS `vt_tip_spam`; | ||
157 | CREATE TABLE `vt_tip_spam` ( | ||
158 | `tip_spam_id` int(11) NOT NULL AUTO_INCREMENT, | ||
159 | `moderated_by` int(11) DEFAULT NULL, | ||
160 | `moderated_on` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
161 | `tip_id` int(11) DEFAULT NULL, | ||
162 | `summary` varchar(200) DEFAULT NULL, | ||
163 | `tip` longtext, | ||
164 | `version` enum('5.7','6.0') DEFAULT NULL, | ||
165 | `complexity` enum('basic','intermediate','advanced') DEFAULT NULL, | ||
166 | `last_updated_by_email` varchar(100) DEFAULT NULL, | ||
167 | `last_update_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
168 | `created_by` varchar(40) DEFAULT NULL, | ||
169 | `created_by_email` varchar(100) DEFAULT NULL, | ||
170 | `creation_date` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', | ||
171 | `ratings` int(11) DEFAULT NULL, | ||
172 | `rating_score` int(11) DEFAULT NULL, | ||
173 | `viewed` int(11) DEFAULT NULL, | ||
174 | PRIMARY KEY (`tip_spam_id`) | ||
175 | ) ENGINE=MyISAM AUTO_INCREMENT=177 DEFAULT CHARSET=latin1; | ||
176 | |||
177 | DROP TABLE IF EXISTS `vt_tip_views`; | ||
178 | CREATE TABLE `vt_tip_views` ( | ||
179 | `creation_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | ||
180 | `tip_id` int(11) DEFAULT NULL, | ||
181 | `ip` varchar(255) DEFAULT NULL, | ||
182 | KEY `vt_tip_views_n1` (`ip`) | ||
183 | ) ENGINE=MyISAM DEFAULT CHARSET=latin1; | ||