Project

General

Profile

1
-- MySQL dump 10.13  Distrib 5.5.28, for debian-linux-gnu (x86_64)
2
--
3
-- Host: localhost    Database: salvias_users
4
-- ------------------------------------------------------
5
-- Server version	5.5.28-0ubuntu0.12.04.3
6

    
7
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
8
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
9
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
10
/*!40101 SET NAMES latin1 */;
11
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
12
/*!40103 SET TIME_ZONE='+00:00' */;
13
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
14
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
15
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,POSTGRESQL' */;
16
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
17

    
18
--
19
-- Table structure for table "affiliation_lookup"
20
--
21

    
22
DROP TABLE IF EXISTS "affiliation_lookup";
23
/*!40101 SET @saved_cs_client     = @@character_set_client */;
24
/*!40101 SET character_set_client = utf8 */;
25
CREATE TABLE "affiliation_lookup" (
26
  "affiliation_id" mediumint(9) NOT NULL,
27
  "description" varchar(200) NOT NULL DEFAULT '',
28
  PRIMARY KEY ("affiliation_id"),
29
  UNIQUE KEY "description" ("description")
30
);
31
/*!40101 SET character_set_client = @saved_cs_client */;
32

    
33
--
34
-- Table structure for table "applications"
35
--
36

    
37
DROP TABLE IF EXISTS "applications";
38
/*!40101 SET @saved_cs_client     = @@character_set_client */;
39
/*!40101 SET character_set_client = utf8 */;
40
CREATE TABLE "applications" (
41
  "app_id" mediumint(9) NOT NULL,
42
  "description" varchar(150) DEFAULT NULL,
43
  "name" varchar(50) NOT NULL DEFAULT '',
44
  "admin_email" varchar(100) DEFAULT NULL,
45
  "http_location" varchar(255) DEFAULT NULL,
46
  PRIMARY KEY ("app_id"),
47
  UNIQUE KEY "name" ("name")
48
);
49
/*!40101 SET character_set_client = @saved_cs_client */;
50

    
51
--
52
-- Table structure for table "country"
53
--
54

    
55
DROP TABLE IF EXISTS "country";
56
/*!40101 SET @saved_cs_client     = @@character_set_client */;
57
/*!40101 SET character_set_client = utf8 */;
58
CREATE TABLE "country" (
59
  "country" varchar(50) DEFAULT NULL,
60
  "country_id" mediumint(9) NOT NULL,
61
  PRIMARY KEY ("country_id")
62
);
63
/*!40101 SET character_set_client = @saved_cs_client */;
64

    
65
--
66
-- Table structure for table "institution_lookup"
67
--
68

    
69
DROP TABLE IF EXISTS "institution_lookup";
70
/*!40101 SET @saved_cs_client     = @@character_set_client */;
71
/*!40101 SET character_set_client = utf8 */;
72
CREATE TABLE "institution_lookup" (
73
  "institution_id" int(11) NOT NULL,
74
  "Address" varchar(100) DEFAULT NULL,
75
  "City" varchar(80) DEFAULT NULL,
76
  "State" char(2) DEFAULT NULL,
77
  "Zipcode" varchar(10) DEFAULT NULL,
78
  "Country" varchar(50) DEFAULT NULL,
79
  "IsHerbarium" tinyint(1) NOT NULL DEFAULT '0',
80
  "Phone" varchar(20) DEFAULT NULL,
81
  "Fax" varchar(20) DEFAULT NULL,
82
  "Email" varchar(120) DEFAULT NULL,
83
  "URL" varchar(250) DEFAULT NULL,
84
  "Spec_URL" varchar(250) DEFAULT NULL,
85
  "Tx_URL" varchar(250) DEFAULT NULL,
86
  "Name" varchar(150) NOT NULL DEFAULT '',
87
  PRIMARY KEY ("institution_id")
88
);
89
/*!40101 SET character_set_client = @saved_cs_client */;
90

    
91
--
92
-- Table structure for table "ipr"
93
--
94

    
95
DROP TABLE IF EXISTS "ipr";
96
/*!40101 SET @saved_cs_client     = @@character_set_client */;
97
/*!40101 SET character_set_client = utf8 */;
98
CREATE TABLE "ipr" (
99
  "IPR_ID" int(10) unsigned NOT NULL DEFAULT '0',
100
  "ipr_general" longtext NOT NULL,
101
  "ipr_general_updated" date NOT NULL DEFAULT '0000-00-00',
102
  "ipr_updated_by" varchar(50) NOT NULL DEFAULT '',
103
  "ipr_general_version" varchar(10) NOT NULL DEFAULT '',
104
  PRIMARY KEY ("IPR_ID")
105
);
106
/*!40101 SET character_set_client = @saved_cs_client */;
107

    
108
--
109
-- Table structure for table "licence_lookup"
110
--
111

    
112
DROP TABLE IF EXISTS "licence_lookup";
113
/*!40101 SET @saved_cs_client     = @@character_set_client */;
114
/*!40101 SET character_set_client = utf8 */;
115
CREATE TABLE "licence_lookup" (
116
  "id" mediumint(9) NOT NULL,
117
  "version" varchar(5) NOT NULL DEFAULT '',
118
  "filename" varchar(30) NOT NULL DEFAULT '',
119
  "created" date NOT NULL DEFAULT '0000-00-00',
120
  "status" char(1) NOT NULL DEFAULT 'A',
121
  "ipr_brief_text" longtext,
122
  PRIMARY KEY ("id")
123
);
124
/*!40101 SET character_set_client = @saved_cs_client */;
125

    
126
--
127
-- Table structure for table "licence_user_lookup"
128
--
129

    
130
DROP TABLE IF EXISTS "licence_user_lookup";
131
/*!40101 SET @saved_cs_client     = @@character_set_client */;
132
/*!40101 SET character_set_client = utf8 */;
133
CREATE TABLE "licence_user_lookup" (
134
  "username" varchar(30) NOT NULL DEFAULT '',
135
  "licence_id" mediumint(9) NOT NULL DEFAULT '0',
136
  "accepted" char(1) NOT NULL DEFAULT '',
137
  "date" date NOT NULL DEFAULT '0000-00-00'
138
);
139
/*!40101 SET character_set_client = @saved_cs_client */;
140

    
141
--
142
-- Table structure for table "page_access"
143
--
144

    
145
DROP TABLE IF EXISTS "page_access";
146
/*!40101 SET @saved_cs_client     = @@character_set_client */;
147
/*!40101 SET character_set_client = utf8 */;
148
CREATE TABLE "page_access" (
149
  "page" varchar(80) NOT NULL DEFAULT '',
150
  "group_id" int(11) NOT NULL DEFAULT '0',
151
  "app_id" int(11) NOT NULL DEFAULT '0',
152
  PRIMARY KEY ("page","group_id"),
153
  KEY "app_id" ("app_id"),
154
  FULLTEXT KEY "page" ("page")
155
);
156
/*!40101 SET character_set_client = @saved_cs_client */;
157

    
158
--
159
-- Table structure for table "page_define"
160
--
161

    
162
DROP TABLE IF EXISTS "page_define";
163
/*!40101 SET @saved_cs_client     = @@character_set_client */;
164
/*!40101 SET character_set_client = utf8 */;
165
CREATE TABLE "page_define" (
166
  "page" varchar(80) NOT NULL DEFAULT '',
167
  "app_id" int(11) NOT NULL DEFAULT '0',
168
  "fail_msg" varchar(250) DEFAULT NULL,
169
  "description" varchar(250) DEFAULT NULL,
170
  "allow_request" tinyint(1) NOT NULL DEFAULT '0',
171
  "show_description" tinyint(1) NOT NULL DEFAULT '0',
172
  PRIMARY KEY ("page","app_id"),
173
  KEY "allow_request" ("allow_request"),
174
  KEY "show_description" ("show_description")
175
);
176
/*!40101 SET character_set_client = @saved_cs_client */;
177

    
178
--
179
-- Table structure for table "page_requests"
180
--
181

    
182
DROP TABLE IF EXISTS "page_requests";
183
/*!40101 SET @saved_cs_client     = @@character_set_client */;
184
/*!40101 SET character_set_client = utf8 */;
185
CREATE TABLE "page_requests" (
186
  "id" mediumint(9) NOT NULL,
187
  "page" varchar(80) NOT NULL DEFAULT '',
188
  "username" varchar(30) NOT NULL DEFAULT '',
189
  "denied" tinyint(1) NOT NULL DEFAULT '0',
190
  "comments" varchar(255) DEFAULT NULL,
191
  PRIMARY KEY ("id")
192
);
193
/*!40101 SET character_set_client = @saved_cs_client */;
194

    
195
--
196
-- Table structure for table "tbl_banned"
197
--
198

    
199
DROP TABLE IF EXISTS "tbl_banned";
200
/*!40101 SET @saved_cs_client     = @@character_set_client */;
201
/*!40101 SET character_set_client = utf8 */;
202
CREATE TABLE "tbl_banned" (
203
  "ip" varchar(16) NOT NULL DEFAULT '',
204
  "app_id" int(11) DEFAULT NULL,
205
  PRIMARY KEY ("ip"),
206
  KEY "app_id" ("app_id")
207
);
208
/*!40101 SET character_set_client = @saved_cs_client */;
209

    
210
--
211
-- Table structure for table "tbl_dl"
212
--
213

    
214
DROP TABLE IF EXISTS "tbl_dl";
215
/*!40101 SET @saved_cs_client     = @@character_set_client */;
216
/*!40101 SET character_set_client = utf8 */;
217
CREATE TABLE "tbl_dl" (
218
  "dl_id" bigint(20) unsigned NOT NULL,
219
  "dl_login_id" bigint(20) NOT NULL DEFAULT '0',
220
  "dl_target" varchar(50) NOT NULL DEFAULT '',
221
  "dl_target_url" varchar(250) NOT NULL DEFAULT '',
222
  "dl_timestamp" timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
223
  PRIMARY KEY ("dl_id")
224
);
225
/*!40101 SET character_set_client = @saved_cs_client */;
226

    
227
--
228
-- Table structure for table "tbl_dl_login"
229
--
230

    
231
DROP TABLE IF EXISTS "tbl_dl_login";
232
/*!40101 SET @saved_cs_client     = @@character_set_client */;
233
/*!40101 SET character_set_client = utf8 */;
234
CREATE TABLE "tbl_dl_login" (
235
  "dl_login_id" bigint(20) unsigned NOT NULL,
236
  "dl_page_src" varchar(250) NOT NULL DEFAULT '',
237
  "dl_page_target" varchar(250) NOT NULL DEFAULT '',
238
  "lname" varchar(50) NOT NULL DEFAULT '',
239
  "fname" varchar(50) NOT NULL DEFAULT '',
240
  "institution" varchar(200) DEFAULT NULL,
241
  "email" varchar(200) NOT NULL DEFAULT '',
242
  "comments" blob,
243
  "timestamp" timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
244
  PRIMARY KEY ("dl_login_id")
245
);
246
/*!40101 SET character_set_client = @saved_cs_client */;
247

    
248
--
249
-- Table structure for table "tbl_group"
250
--
251

    
252
DROP TABLE IF EXISTS "tbl_group";
253
/*!40101 SET @saved_cs_client     = @@character_set_client */;
254
/*!40101 SET character_set_client = utf8 */;
255
CREATE TABLE "tbl_group" (
256
  "username" varchar(40) NOT NULL DEFAULT '',
257
  "gid" int(11) NOT NULL DEFAULT '-1',
258
  PRIMARY KEY ("username","gid")
259
);
260
/*!40101 SET character_set_client = @saved_cs_client */;
261

    
262
--
263
-- Table structure for table "tbl_group_define"
264
--
265

    
266
DROP TABLE IF EXISTS "tbl_group_define";
267
/*!40101 SET @saved_cs_client     = @@character_set_client */;
268
/*!40101 SET character_set_client = utf8 */;
269
CREATE TABLE "tbl_group_define" (
270
  "gid" int(11) NOT NULL,
271
  "app_id" int(11) NOT NULL DEFAULT '0',
272
  "group_name" varchar(80) NOT NULL DEFAULT '',
273
  "description" varchar(200) DEFAULT NULL,
274
  "parent_gid" int(11) DEFAULT NULL,
275
  "group_admin_email" varchar(80) NOT NULL DEFAULT '',
276
  "allow_request" tinyint(1) NOT NULL DEFAULT '0',
277
  PRIMARY KEY ("gid"),
278
  KEY "group_admin_email" ("group_admin_email"),
279
  KEY "allow_request" ("allow_request")
280
);
281
/*!40101 SET character_set_client = @saved_cs_client */;
282

    
283
--
284
-- Table structure for table "tbl_log"
285
--
286

    
287
DROP TABLE IF EXISTS "tbl_log";
288
/*!40101 SET @saved_cs_client     = @@character_set_client */;
289
/*!40101 SET character_set_client = utf8 */;
290
CREATE TABLE "tbl_log" (
291
  "log_id" int(11) NOT NULL,
292
  "lastusage" int(11) DEFAULT NULL,
293
  "timestamp" int(11) NOT NULL DEFAULT '0',
294
  "ip" varchar(16) NOT NULL DEFAULT 'no ip logged',
295
  "username" varchar(40) DEFAULT NULL,
296
  "action" varchar(40) DEFAULT NULL,
297
  "app_id" int(11) DEFAULT NULL,
298
  PRIMARY KEY ("log_id"),
299
  UNIQUE KEY "timestamp" ("timestamp","ip"),
300
  KEY "app_id" ("app_id")
301
);
302
/*!40101 SET character_set_client = @saved_cs_client */;
303

    
304
--
305
-- Table structure for table "tbl_users"
306
--
307

    
308
DROP TABLE IF EXISTS "tbl_users";
309
/*!40101 SET @saved_cs_client     = @@character_set_client */;
310
/*!40101 SET character_set_client = utf8 */;
311
CREATE TABLE "tbl_users" (
312
  "id" mediumint(9) NOT NULL,
313
  "username" varchar(30) NOT NULL DEFAULT '',
314
  "password" varchar(250) DEFAULT NULL,
315
  "lname" varchar(25) DEFAULT NULL,
316
  "fname" varchar(25) DEFAULT NULL,
317
  "email" varchar(100) DEFAULT NULL,
318
  "alt_email" varchar(60) DEFAULT NULL,
319
  "html_link_id" mediumint(9) DEFAULT NULL,
320
  "address" varchar(200) DEFAULT NULL,
321
  "city" varchar(100) DEFAULT NULL,
322
  "state" varchar(11) DEFAULT NULL,
323
  "zip" varchar(15) DEFAULT NULL,
324
  "phone" varchar(25) DEFAULT NULL,
325
  "country_id" int(11) DEFAULT NULL,
326
  "room_number" varchar(10) DEFAULT NULL,
327
  "institution_id" int(11) DEFAULT NULL,
328
  "Department" varchar(50) DEFAULT NULL,
329
  "spec_dq_priority" tinyint(4) NOT NULL DEFAULT '0',
330
  PRIMARY KEY ("id"),
331
  UNIQUE KEY "login" ("username")
332
);
333
/*!40101 SET character_set_client = @saved_cs_client */;
334

    
335
--
336
-- Table structure for table "user_status"
337
--
338

    
339
DROP TABLE IF EXISTS "user_status";
340
/*!40101 SET @saved_cs_client     = @@character_set_client */;
341
/*!40101 SET character_set_client = utf8 */;
342
CREATE TABLE "user_status" (
343
  "username" varchar(30) NOT NULL DEFAULT '',
344
  "ip" varchar(16) DEFAULT NULL,
345
  "lastusage" int(11) NOT NULL DEFAULT '0',
346
  "app_id" mediumint(9) NOT NULL DEFAULT '0',
347
  "tries" smallint(6) DEFAULT NULL,
348
  "nextlogin" int(11) DEFAULT NULL,
349
  PRIMARY KEY ("username","app_id"),
350
  KEY "ip" ("ip")
351
);
352
/*!40101 SET character_set_client = @saved_cs_client */;
353
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
354

    
355
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
356
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
357
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
358
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
359
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
360
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
361
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
362

    
363
-- Dump completed on 2012-12-11  9:53:05
(5-5/6)