· 7 years ago · Jan 18, 2019, 10:58 AM
1protected function createTable()
2 {
3 $requete= "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."monmodule_comment` (
4 `id_monmodule_comment` int(11) NOT NULL AUTO_INCREMENT,
5 `id_product` int(11) NOT NULL,
6 `grade` tinyint(1) NOT NULL,
7 `comment` text NOT NULL,
8 `date_add` datetime NOT NULL,
9 PRIMARY KEY (`id_monmodule_comment`)
10 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;";
11 Db::getInstance()->execute($requete);
12 }