Файл: base.sql
Строк: 106
CREATE TABLE IF NOT EXISTS `ads` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`link` varchar(150) NOT NULL,
`time` int(20) NOT NULL,
`oute`
varchar(5) NOT NULL DEFAULT '0',
`pozic` varchar(2) NOT NULL,
`name`
varchar(100) NOT NULL,
`srok` int(20) DEFAULT '0',
PRIMARY KEY (`id`)
)
ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT
EXISTS `cat` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` text NOT
NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS `chat` (
`id` int(7) NOT
NULL AUTO_INCREMENT,
`id_room` int(5) NOT NULL,
`author_id` int(5)
DEFAULT NULL,
`text` text NOT NULL,
`time` varchar(50) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1
;
CREATE TABLE IF NOT EXISTS `design` (
`id` int(5) NOT NULL
AUTO_INCREMENT,
`name` varchar(90) NOT NULL,
`link` varchar(20) NOT
NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
AUTO_INCREMENT=3 ;
INSERT INTO `design` (`id`, `name`, `link`) VALUES
(1,
'Зимний (от Selemet)', 'styles/1/style.css'),
(2, 'Flat
(Плоский)', '/styles/2/style.css');
CREATE TABLE IF NOT EXISTS
`dialog` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`kto` int(15) DEFAULT
'0',
`komu` int(15) DEFAULT '0',
`time` int(15) DEFAULT '0',
`last`
int(15) DEFAULT '0',
`new` int(7) DEFAULT '0',
PRIMARY KEY (`id`)
)
ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT
EXISTS `files` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` text NOT
NULL,
`file` text NOT NULL,
`size` text NOT NULL,
`cat` varchar(80)
NOT NULL,
`podcat` varchar(80) NOT NULL,
`time` int(13) NOT NULL,
`genre` varchar(51) NOT NULL,
`year` varchar(80) NOT NULL,
`artist`
varchar(80) NOT NULL,
`down` int(11) NOT NULL,
`view` int(11) NOT
NULL,
`bitrate` text NOT NULL,
`duration` text NOT NULL,
PRIMARY KEY
(`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE
TABLE IF NOT EXISTS `forum` (
`id` int(5) NOT NULL AUTO_INCREMENT,
`razdel` varchar(5) NOT NULL,
`name` varchar(90) NOT NULL,
PRIMARY KEY
(`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE
TABLE IF NOT EXISTS `mail` (
`id` int(5) NOT NULL AUTO_INCREMENT,
`kto`
int(5) NOT NULL,
`komu` int(5) NOT NULL,
`text` text NOT NULL,
`time`
int(15) NOT NULL,
`status` int(5) NOT NULL,
`pole_a` int(5) DEFAULT
NULL,
`pole_b` int(5) DEFAULT NULL,
`pole_c` int(5) DEFAULT NULL,
`file` varchar(300) DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM
DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS
`news` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`time` int(11) NOT
NULL,
`nazv` text,
`msg` text,
PRIMARY KEY (`id`)
) ENGINE=MyISAM
DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS `obmen`
(
`id` int(111) NOT NULL AUTO_INCREMENT,
`id_cat` varchar(70) NOT
NULL,
`avtor` text NOT NULL,
`time` int(11) NOT NULL,
`link`
varchar(20) NOT NULL,
`opis` varchar(400) NOT NULL,
`name` varchar(150)
DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8
AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS `podcat` (
`id` int(11)
NOT NULL AUTO_INCREMENT,
`cat` varchar(80) NOT NULL,
`name` text NOT
NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS `posts` (
`id` int(7) NOT
NULL AUTO_INCREMENT,
`id_theme` int(5) NOT NULL,
`id_forum` int(3) NOT
NULL,
`author_id` int(5) DEFAULT NULL,
`text` text NOT NULL,
`time`
varchar(50) NOT NULL,
`ip` varchar(15) NOT NULL,
`ua` varchar(20)
DEFAULT NULL,
`pages` varchar(8) DEFAULT NULL,
`status` int(2) NOT
NULL,
`file` varchar(200) DEFAULT '0',
PRIMARY KEY (`id`)
)
ENGINE=MyISAM DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE TABLE IF
NOT EXISTS `razdel` (
`id` int(5) NOT NULL AUTO_INCREMENT,
`name`
varchar(90) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT
CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS `setting` (
`title` varchar(90) NOT NULL,
`head` varchar(150) NOT NULL,
`copy`
varchar(150) NOT NULL,
`rega` varchar(5) NOT NULL,
`design`
varchar(100) NOT NULL,
`flood` int(3) DEFAULT '0'
) ENGINE=MyISAM DEFAULT
CHARSET=cp1251;
INSERT INTO `setting` (`title`, `head`, `copy`, `rega`,
`design`, `flood`) VALUES
('X-CMS', 'Сайт', '© 2015 | by Denis', '1',
'styles/1/style.css', 1);
CREATE TABLE IF NOT EXISTS `themes` (
`id`
int(5) NOT NULL AUTO_INCREMENT,
`id_forum` int(5) NOT NULL,
`status`
int(1) NOT NULL,
`name` varchar(40) NOT NULL,
`author_id` int(5)
DEFAULT NULL,
`time` int(15) NOT NULL,
`avtor` int(5) DEFAULT NULL,
`time_last` int(15) DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM
DEFAULT CHARSET=cp1251 AUTO_INCREMENT=1 ;
CREATE TABLE IF NOT EXISTS
`user` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`login` varchar(32) NOT
NULL,
`password` varchar(32) NOT NULL,
`time` int(11) NOT NULL,
`mail` varchar(32) DEFAULT NULL,
`level` enum('0','1') DEFAULT '0',
`names` varchar(55) DEFAULT '0',
`inf` varchar(255) DEFAULT '0',
`icq`
varchar(25) DEFAULT '0',
`balans` varchar(100) DEFAULT '0.0',
`city`
varchar(15) DEFAULT '0',
`key` varchar(50) DEFAULT NULL,
`ban` int(1)
DEFAULT '0',
`bday` int(2) DEFAULT '1',
`bmon` int(2) DEFAULT '1',
`byea` int(4) DEFAULT '2000',
`posts` int(50) DEFAULT '0',
`postschat`
int(50) DEFAULT '0',
`sex` int(5) DEFAULT '1',
`avatar` varchar(100)
DEFAULT 'default.png',
`design` varchar(50) DEFAULT
'styles/1/style.css',
`visit` int(15) DEFAULT '0',
`auth` int(15)
DEFAULT '0',
`flood` int(15) DEFAULT '0',
PRIMARY KEY (`id`)
)
ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ;
--
-- Дамп
данных таблицы `user`
--
INSERT INTO `user` (`id`, `login`,
`password`, `time`, `mail`, `level`, `names`, `inf`, `icq`, `balans`,
`city`, `key`, `ban`, `bday`, `bmon`, `byea`, `posts`, `postschat`, `sex`,
`avatar`, `design`, `visit`, `auth`, `flood`) VALUES
(1, 'admin',
'0a2e445583b57657758b8117f804cf75', 1292352782, '0', '1', 'Denis',
'x-cms.ga', '10025', '4198', 'Default city', '', 0, 99, 99, 9999, 2598, 13,
1, '863788xcms.png', 'styles/1/style.css', 1422193439, 1422179912,
1422193378);