[Astrospaces-commits] SF.net SVN: astrospaces: [83] trunk/develop/new-schema.sql
Brought to you by:
p3net
From: <fr...@us...> - 2007-08-01 20:09:36
|
Revision: 83 http://astrospaces.svn.sourceforge.net/astrospaces/?rev=83&view=rev Author: frcole Date: 2007-08-01 13:09:38 -0700 (Wed, 01 Aug 2007) Log Message: ----------- Split out profile field info into a separate table from user admin data. Will add a seperate table for dynamic/extensible profile fields later. This is necessary to make editing and otherwise maintaining Account data later on. -- frc Modified Paths: -------------- trunk/develop/new-schema.sql Modified: trunk/develop/new-schema.sql =================================================================== --- trunk/develop/new-schema.sql 2007-08-01 15:11:05 UTC (rev 82) +++ trunk/develop/new-schema.sql 2007-08-01 20:09:38 UTC (rev 83) @@ -1,132 +1,138 @@ -DROP TABLE IF EXISTS `as_actions`; -CREATE TABLE `as_actions` ( - `action_id` int(10) unsigned NOT NULL auto_increment, - `action_timestamp` int(10) unsigned NOT NULL, - `action` int(2) unsigned NOT NULL, - `for` int(11) unsigned NOT NULL, - PRIMARY KEY (`action_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_blog`; -CREATE TABLE `as_blog` ( - `blog_id` int(10) unsigned NOT NULL auto_increment, - `title` varchar(45) NOT NULL, - `blog_timestamp` int(10) unsigned NOT NULL, - `content` text NOT NULL, - `author_id` int(11) unsigned NOT NULL, - PRIMARY KEY (`blog_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_blog_comment`; -CREATE TABLE `as_blog_comment` ( - `comment_id` int(10) unsigned NOT NULL auto_increment, - `post_id` int(10) unsigned NOT NULL, - `author_id` int(10) unsigned NOT NULL, - `comment` text NOT NULL, - `post_timestamp` int(10) unsigned NOT NULL, - PRIMARY KEY (`comment_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_comments`; -CREATE TABLE `as_comments` ( - `comment_id` int(10) unsigned NOT NULL auto_increment, - `comment_timestamp` int(10) unsigned NOT NULL, - `poster_id` int(11) unsigned NOT NULL, - `recipient_id` int(11) unsigned NOT NULL, - `comment` text NOT NULL, - PRIMARY KEY (`comment_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; - -DROP TABLE IF EXISTS `as_friends`; -CREATE TABLE `as_friends` ( - `couple_id` int(10) unsigned NOT NULL auto_increment, - `user1_id` int(10) unsigned NOT NULL, - `user2_id` int(10) unsigned NOT NULL, - `accepted` tinyint(1) unsigned NOT NULL, - PRIMARY KEY (`couple_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; - -DROP TABLE IF EXISTS `as_group_resolver`; -CREATE TABLE `as_group_resolver` ( - `pair_id` int(10) unsigned NOT NULL auto_increment, - `user_id` int(10) unsigned NOT NULL, - `group_id` int(10) unsigned NOT NULL, - `join_date` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', - PRIMARY KEY (`pair_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; - -DROP TABLE IF EXISTS `as_groups`; -CREATE TABLE `as_groups` ( - `group_id` int(10) unsigned NOT NULL auto_increment, - `name` varchar(45) NOT NULL, - `founder` int(11) unsigned NOT NULL, - `create_timestamp` int(10) unsigned NOT NULL, - PRIMARY KEY (`group_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; - -DROP TABLE IF EXISTS `as_image_comments`; -CREATE TABLE `as_image_comments` ( - `comment_id` int(10) unsigned NOT NULL auto_increment, - `image_id` int(11) unsigned NOT NULL, - `post_timestamp` int(10) unsigned NOT NULL, - `author` int(11) unsigned NOT NULL, - `comment` text NOT NULL, - PRIMARY KEY (`comment_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_images`; -CREATE TABLE `as_images` ( - `img_id` int(10) unsigned NOT NULL auto_increment, - `owner_id` int(10) unsigned NOT NULL, - `content` blob NOT NULL COMMENT 'binary image', - `desc` text NOT NULL, - `width` int(4) unsigned NOT NULL, - `height` int(4) unsigned NOT NULL, - `name` text NOT NULL, - `views` int(6) unsigned NOT NULL, - `mime_type` varchar(20) NOT NULL, - PRIMARY KEY (`img_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_private_messages`; -CREATE TABLE `as_private_messages` ( - `message_id` int(10) unsigned NOT NULL auto_increment, - `sender_id` int(11) unsigned NOT NULL, - `recipient_id` int(11) unsigned NOT NULL, - `send_date` int(10) unsigned NOT NULL, - `subject` varchar(80) NOT NULL, - `message` text NOT NULL, - `read` tinyint(1) unsigned NOT NULL default '0', - PRIMARY KEY (`message_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; - -DROP TABLE IF EXISTS `as_sessions`; -CREATE TABLE `as_sessions` ( - `session_id` int(10) unsigned NOT NULL auto_increment, - `user_id` int(11) unsigned NOT NULL, - `ip` varchar(12) NOT NULL, - `last_update` int(10) unsigned NOT NULL, - PRIMARY KEY (`session_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; - -DROP TABLE IF EXISTS `as_users`; -CREATE TABLE `as_users` ( - `user_id` int(10) unsigned NOT NULL auto_increment, - `display_name` varchar(45) NOT NULL, - `password` varchar(16) NOT NULL, - `join_date` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', - `last_login` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', - `time_offset` tinyint(3) unsigned NOT NULL, - `blurb` text NOT NULL, - `email` varchar(60) NOT NULL, - `aim` varchar(45) NOT NULL, - `yim` varchar(45) NOT NULL, - `jabber` varchar(45) NOT NULL, - `irc` varchar(45) NOT NULL, - `icq` varchar(45) NOT NULL, - `msn` varchar(45) NOT NULL, - `user_image` int(11) unsigned NOT NULL, - `clean_url` varchar(45) NOT NULL, - `privacy` tinyint(1) unsigned NOT NULL default '0', - PRIMARY KEY (`user_id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; \ No newline at end of file +DROP TABLE IF EXISTS `as_actions`; +CREATE TABLE `as_actions` ( + `action_id` int(10) unsigned NOT NULL auto_increment, + `action_timestamp` int(10) unsigned NOT NULL, + `action` int(2) unsigned NOT NULL, + `for` int(11) unsigned NOT NULL, + PRIMARY KEY (`action_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_blog`; +CREATE TABLE `as_blog` ( + `blog_id` int(10) unsigned NOT NULL auto_increment, + `title` varchar(45) NOT NULL, + `blog_timestamp` int(10) unsigned NOT NULL, + `content` text NOT NULL, + `author_id` int(11) unsigned NOT NULL, + PRIMARY KEY (`blog_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_blog_comment`; +CREATE TABLE `as_blog_comment` ( + `comment_id` int(10) unsigned NOT NULL auto_increment, + `post_id` int(10) unsigned NOT NULL, + `author_id` int(10) unsigned NOT NULL, + `comment` text NOT NULL, + `post_timestamp` int(10) unsigned NOT NULL, + PRIMARY KEY (`comment_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_comments`; +CREATE TABLE `as_comments` ( + `comment_id` int(10) unsigned NOT NULL auto_increment, + `comment_timestamp` int(10) unsigned NOT NULL, + `poster_id` int(11) unsigned NOT NULL, + `recipient_id` int(11) unsigned NOT NULL, + `comment` text NOT NULL, + PRIMARY KEY (`comment_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; + +DROP TABLE IF EXISTS `as_friends`; +CREATE TABLE `as_friends` ( + `couple_id` int(10) unsigned NOT NULL auto_increment, + `user1_id` int(10) unsigned NOT NULL, + `user2_id` int(10) unsigned NOT NULL, + `accepted` tinyint(1) unsigned NOT NULL, + PRIMARY KEY (`couple_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; + +DROP TABLE IF EXISTS `as_group_resolver`; +CREATE TABLE `as_group_resolver` ( + `pair_id` int(10) unsigned NOT NULL auto_increment, + `user_id` int(10) unsigned NOT NULL, + `group_id` int(10) unsigned NOT NULL, + `join_date` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', + PRIMARY KEY (`pair_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; + +DROP TABLE IF EXISTS `as_groups`; +CREATE TABLE `as_groups` ( + `group_id` int(10) unsigned NOT NULL auto_increment, + `name` varchar(45) NOT NULL, + `founder` int(11) unsigned NOT NULL, + `create_timestamp` int(10) unsigned NOT NULL, + PRIMARY KEY (`group_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; + +DROP TABLE IF EXISTS `as_image_comments`; +CREATE TABLE `as_image_comments` ( + `comment_id` int(10) unsigned NOT NULL auto_increment, + `image_id` int(11) unsigned NOT NULL, + `post_timestamp` int(10) unsigned NOT NULL, + `author` int(11) unsigned NOT NULL, + `comment` text NOT NULL, + PRIMARY KEY (`comment_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_images`; +CREATE TABLE `as_images` ( + `img_id` int(10) unsigned NOT NULL auto_increment, + `owner_id` int(10) unsigned NOT NULL, + `content` blob NOT NULL COMMENT 'binary image', + `desc` text NOT NULL, + `width` int(4) unsigned NOT NULL, + `height` int(4) unsigned NOT NULL, + `name` text NOT NULL, + `views` int(6) unsigned NOT NULL, + `mime_type` varchar(20) NOT NULL, + PRIMARY KEY (`img_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_private_messages`; +CREATE TABLE `as_private_messages` ( + `message_id` int(10) unsigned NOT NULL auto_increment, + `sender_id` int(11) unsigned NOT NULL, + `recipient_id` int(11) unsigned NOT NULL, + `send_date` int(10) unsigned NOT NULL, + `subject` varchar(80) NOT NULL, + `message` text NOT NULL, + `read` tinyint(1) unsigned NOT NULL default '0', + PRIMARY KEY (`message_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_sessions`; +CREATE TABLE `as_sessions` ( + `session_id` int(10) unsigned NOT NULL auto_increment, + `user_id` int(11) unsigned NOT NULL, + `ip` varchar(12) NOT NULL, + `last_update` int(10) unsigned NOT NULL, + PRIMARY KEY (`session_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC; + +DROP TABLE IF EXISTS `as_users`; +CREATE TABLE `as_users` ( + `user_id` int(10) unsigned NOT NULL auto_increment, + `password` varchar(16) NOT NULL, + `join_date` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', + `last_login` int(10) unsigned NOT NULL COMMENT 'Unix timestamp', + `time_offset` tinyint(3) unsigned NOT NULL, + `email` varchar(60) NOT NULL, + `user_image` int(11) unsigned NOT NULL, + `privacy` tinyint(1) unsigned NOT NULL default '0', + PRIMARY KEY (`user_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; + +DROP TABLE IF EXISTS `as_static_profile_fields`; +CREATE TABLE `as_users` ( + `user_id` int(10) unsigned NOT NULL auto_increment, + `display_name` varchar(45) NOT NULL, + `blurb` text NOT NULL, + `aim` varchar(45) NOT NULL, + `yim` varchar(45) NOT NULL, + `jabber` varchar(45) NOT NULL, + `irc` varchar(45) NOT NULL, + `icq` varchar(45) NOT NULL, + `msn` varchar(45) NOT NULL, + `user_image` int(11) unsigned NOT NULL, + PRIMARY KEY (`user_id`) +) ENGINE=MyISAM DEFAULT CHARSET=latin1; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |