Location: PHPKode > projects > OneBlog > oneblog/sql.txt
CREATE TABLE `admin` (
  `id` INT(8) NOT NULL AUTO_INCREMENT,
  `name` VARCHAR(30) NOT NULL,
  `password` VARCHAR(255) NOT NULL,
  `date` DATETIME NOT NULL,
  UNIQUE INDEX name_unique (`name`),
  PRIMARY KEY (`id`)
) ENGINE=MyISAM;

CREATE TABLE `blog` (
  `blog_id` INT(11) NOT NULL AUTO_INCREMENT,
  `title` VARCHAR(70) NOT NULL,
  `author` VARCHAR(50) NOT NULL,
  `post` TEXT NOT NULL,
  `date` DATETIME NOT NULL,
  PRIMARY KEY (`blog_id`)
) ENGINE=MYISAM;


CREATE TABLE `comments` (
  `blog_id` INT(11) NOT NULL AUTO_INCREMENT,
  `blog_id2` INT(11) NOT NULL,
  `title` VARCHAR(70) NOT NULL,
  `author` VARCHAR(50) NOT NULL,
  `comment` TEXT NOT NULL,
  `date` DATETIME NOT NULL,
  PRIMARY KEY (`blog_id`)
) ENGINE=MYISAM;

CREATE TABLE `badwords` (
  `id` TINYINT(3) UNSIGNED NOT NULL AUTO_INCREMENT,
  `word` VARCHAR(100) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MYISAM;
Return current item: OneBlog