|
|
|
CREATE TABLE `messages` (
|
|
|
|
`mail_id` varchar(255) NOT NULL default '',
|
|
|
|
`date_day` date,
|
|
|
|
`date_time` time,
|
|
|
|
`remote_ip` varchar(255) default NULL,
|
|
|
|
`remote_host` varchar(255) default NULL,
|
|
|
|
`remote_info` varchar(255) default NULL,
|
|
|
|
`auth_user` varchar(30) default NULL,
|
|
|
|
`sender` varchar(255) default NULL,
|
|
|
|
`subject` varchar(255) default NULL,
|
|
|
|
`header_size` int(11) default NULL,
|
|
|
|
`body_size` int(11) default NULL,
|
|
|
|
`spam_status` float default NULL,
|
|
|
|
`deny` set('YES','NO') default NULL,
|
|
|
|
`deny_plugin` varchar(100) default '',
|
|
|
|
`deny_code` int(11) default '0',
|
|
|
|
`deny_msg` text,
|
|
|
|
PRIMARY KEY (`mail_id`)
|
|
|
|
) TYPE=InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `rcpts` (
|
|
|
|
`rcpt_id` int(11) NOT NULL auto_increment,
|
|
|
|
`mail_id` varchar(255) NOT NULL default '',
|
|
|
|
`recipient` varchar(255),
|
|
|
|
PRIMARY KEY (`rcpt_id`)
|
|
|
|
) TYPE=InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `message_body` (
|
|
|
|
`bdy_id` int(11) NOT NULL auto_increment,
|
|
|
|
`mail_id` varchar(255) NOT NULL default '',
|
|
|
|
`body` text,
|
|
|
|
PRIMARY KEY (`bdy_id`)
|
|
|
|
) TYPE=InnoDB;
|
|
|
|
|
|
|
|
CREATE TABLE `message_headers` (
|
|
|
|
`header_id` int(11) NOT NULL auto_increment,
|
|
|
|
`mail_id` varchar(255) NOT NULL default '',
|
|
|
|
`header` text,
|
|
|
|
PRIMARY KEY (`header_id`)
|
|
|
|
) TYPE=InnoDB;
|