summaryrefslogtreecommitdiffstats
path: root/database
diff options
context:
space:
mode:
authorDries Buytaert2003-08-20 19:19:13 (GMT)
committerDries Buytaert2003-08-20 19:19:13 (GMT)
commit0431f0700f204ab9941a4791c887024aa4f83ceb (patch)
tree9d2f013bdc3a619164820adcd398b0f344d3df18 /database
parentb79b831152f79b412ce35c91193332c66ba94580 (diff)
- Committed Jeremy's session patch: this brings us one step closer to having
session for anonymous users.
Diffstat (limited to 'database')
-rw-r--r--database/database.mssql13
-rw-r--r--database/database.mysql19
-rw-r--r--database/database.pgsql16
3 files changed, 39 insertions, 9 deletions
diff --git a/database/database.mssql b/database/database.mssql
index 25eb3a1..25aee61 100644
--- a/database/database.mssql
+++ b/database/database.mssql
@@ -252,6 +252,16 @@ CREATE TABLE [dbo].[search_index] (
) ON [PRIMARY]
GO
+CREATE TABLE sessions (
+ [sid] [varchar] (32) NOT NULL,
+ [uid] [int] NOT NULL,
+ [hostname] [varchar] (128) NOT NULL,
+ [timestamp] [integer] NOT NULL,
+ [session] [text],
+) ON [PRIMARY]
+GO
+
+
CREATE TABLE [dbo].[sequences] (
[name] [varchar] (255) NOT NULL ,
[id] [numeric](10, 0) NOT NULL
@@ -333,14 +343,11 @@ CREATE TABLE [dbo].[users] (
[theme] [varchar] (255) NULL ,
[signature] [varchar] (255) NULL ,
[timestamp] [float] NOT NULL ,
- [hostname] [varchar] (128) NULL ,
[status] [smallint] NOT NULL ,
[timezone] [varchar] (8) NULL ,
[rating] [float] NULL ,
[language] [char] (2) NULL ,
- [sid] [varchar] (128) NULL ,
[init] [varchar] (128) NULL ,
- [session] [text] NULL ,
[data] [varchar] (8000) NULL ,
[rid] [int] NOT NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
diff --git a/database/database.mysql b/database/database.mysql
index 523aa61..00d6ca8 100644
--- a/database/database.mysql
+++ b/database/database.mysql
@@ -361,6 +361,22 @@ CREATE TABLE search_index (
) TYPE=MyISAM;
--
+-- Table structure for table 'sessesions'
+--
+
+
+CREATE TABLE sessions (
+ uid int(10) unsigned NOT NULL,
+ sid varchar(32) NOT NULL default '',
+ hostname varchar(128) NOT NULL default '',
+ timestamp int(11) NOT NULL default '0',
+ session text,
+ KEY uid (uid),
+ KEY sid (sid(4)),
+ KEY timestamp (timestamp)
+) TYPE=MyISAM;
+
+--
-- Table structure for table 'sequences'
--
@@ -491,14 +507,11 @@ CREATE TABLE users (
theme varchar(255) NOT NULL default '',
signature varchar(255) NOT NULL default '',
timestamp int(11) NOT NULL default '0',
- hostname varchar(128) NOT NULL default '',
status tinyint(4) NOT NULL default '0',
timezone varchar(8) default NULL,
rating decimal(8,2) default NULL,
language char(2) NOT NULL default '',
- sid varchar(32) NOT NULL default '',
init varchar(64) default '',
- session text,
data text,
rid int(10) unsigned NOT NULL default '0',
PRIMARY KEY (uid),
diff --git a/database/database.pgsql b/database/database.pgsql
index 63ec8f7..dc08bfc 100644
--- a/database/database.pgsql
+++ b/database/database.pgsql
@@ -361,6 +361,19 @@ CREATE INDEX search_index_lno_idx ON search_index(lno);
CREATE INDEX search_index_word_idx ON search_index(word);
--
+-- Table structure for sessions
+--
+
+CREATE TABLE sessions (
+ uid integer NOT NULL,
+ sid varchar(32) NOT NULL default '',
+ hostname varchar(128) NOT NULL default '',
+ timestamp integer NOT NULL default '0',
+ session text,
+ PRIMARY KEY (sid)
+);
+
+--
-- Table structure for sequences
-- This is only used under MySQL, co commented out
--
@@ -494,14 +507,11 @@ CREATE TABLE users (
theme varchar(255) NOT NULL default '',
signature varchar(255) NOT NULL default '',
timestamp integer NOT NULL default '0',
- hostname varchar(128) NOT NULL default '',
status smallint NOT NULL default '0',
timezone varchar(8) default NULL,
rating decimal(8,2) default NULL,
language char(2) NOT NULL default '',
- sid varchar(32) NOT NULL default '',
init varchar(64) default '',
- session text default '',
data text default '',
rid integer NOT NULL default '0',
PRIMARY KEY (uid),