From 3aecce9022fbf8a475bfe34645d0b64ff895d059 Mon Sep 17 00:00:00 2001 From: ui0ppk Date: Mon, 13 Feb 2023 11:18:43 +0200 Subject: [PATCH] sql fix --- grublox.sql | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/grublox.sql b/grublox.sql index eb2395d..9453bca 100644 --- a/grublox.sql +++ b/grublox.sql @@ -27,7 +27,7 @@ SET time_zone = "+00:00"; -- Table structure for table `catalog` -- -CREATE TABLE `catalog` ( +CREATE TABLE IF NOT EXISTS `catalog` ( `id` int(11) NOT NULL, `name` varchar(50) NOT NULL, `description` varchar(255) NOT NULL, @@ -47,7 +47,7 @@ CREATE TABLE `catalog` ( -- Dumping data for table `catalog` -- -INSERT INTO `catalog` (`id`, `name`, `description`, `creator`, `price`, `type`, `sales`, `thumbnail`, `date`, `lastupdated`, `limited`, `stock`, `state`) VALUES +REPLACE INTO `catalog` (`id`, `name`, `description`, `creator`, `price`, `type`, `sales`, `thumbnail`, `date`, `lastupdated`, `limited`, `stock`, `state`) VALUES (11, 'qzip', 'qzip for sale im bein sold psl help', 1, 1, 'hats', 2, 'https://qzip.lol/assets/img/qzip.png', '2023-02-12 13:25:34', '2023-02-12 13:25:34', 0, 0, 'approved'), (12, 'gzip', 'osdfdssdjs', 1, 1, 'pants', 2231, 'https://cdn-icons-png.flaticon.com/512/29/29505.png', '2023-02-12 13:25:34', '2023-02-12 13:25:34', 1, 0, 'approved'); @@ -57,7 +57,7 @@ INSERT INTO `catalog` (`id`, `name`, `description`, `creator`, `price`, `type`, -- Table structure for table `comments` -- -CREATE TABLE `comments` ( +CREATE TABLE IF NOT EXISTS `comments` ( `id` int(11) NOT NULL, `user` int(11) NOT NULL, `type` varchar(250) NOT NULL, @@ -70,7 +70,7 @@ CREATE TABLE `comments` ( -- Table structure for table `friends` -- -CREATE TABLE `friends` ( +CREATE TABLE IF NOT EXISTS `friends` ( `id` int(11) NOT NULL, `user` int(11) NOT NULL, `state` varchar(50) NOT NULL DEFAULT 'pending', @@ -81,7 +81,7 @@ CREATE TABLE `friends` ( -- Dumping data for table `friends` -- -INSERT INTO `friends` (`id`, `user`, `state`, `friend`) VALUES +REPLACE INTO `friends` (`id`, `user`, `state`, `friend`) VALUES (1, 1, 'approved', 1); -- -------------------------------------------------------- @@ -90,7 +90,7 @@ INSERT INTO `friends` (`id`, `user`, `state`, `friend`) VALUES -- Table structure for table `games` -- -CREATE TABLE `games` ( +CREATE TABLE IF NOT EXISTS `games` ( `id` int(11) NOT NULL, `name` varchar(50) NOT NULL, `description` varchar(255) NOT NULL, @@ -106,7 +106,7 @@ CREATE TABLE `games` ( -- Dumping data for table `games` -- -INSERT INTO `games` (`id`, `name`, `description`, `creator`, `accessKey`, `state`, `date`, `updateddate`, `thumbnail`) VALUES +REPLACE INTO `games` (`id`, `name`, `description`, `creator`, `accessKey`, `state`, `date`, `updateddate`, `thumbnail`) VALUES (1818, 'Crossroads', 'The classic ROBLOX level is back!', 1, '69', '', '2023-02-13 10:38:28', '2023-02-13 10:38:28', ''); -- -------------------------------------------------------- @@ -115,7 +115,7 @@ INSERT INTO `games` (`id`, `name`, `description`, `creator`, `accessKey`, `state -- Table structure for table `jobs` -- -CREATE TABLE `jobs` ( +CREATE TABLE IF NOT EXISTS `jobs` ( `id` int(11) NOT NULL, `jobid` varchar(50) NOT NULL, `placeid` int(11) NOT NULL, @@ -128,7 +128,7 @@ CREATE TABLE `jobs` ( -- Table structure for table `tokens` -- -CREATE TABLE `tokens` ( +CREATE TABLE IF NOT EXISTS `tokens` ( `id` int(11) NOT NULL, `token` varchar(500) NOT NULL, `placeid` int(11) NOT NULL, @@ -143,7 +143,7 @@ CREATE TABLE `tokens` ( -- Table structure for table `users` -- -CREATE TABLE `users` ( +CREATE TABLE IF NOT EXISTS `users` ( `id` int(11) NOT NULL, `username` varchar(20) NOT NULL, `password` varchar(450) NOT NULL, @@ -158,7 +158,7 @@ CREATE TABLE `users` ( -- Dumping data for table `users` -- -INSERT INTO `users` (`id`, `username`, `password`, `date`, `description`, `money`, `lastPaid`, `admin`) VALUES +REPLACE INTO `users` (`id`, `username`, `password`, `date`, `description`, `money`, `lastPaid`, `admin`) VALUES (1, 'qzip', '$2y$10$AS751CiLVhlbLKo.T9CSVuc81sk8OxC2aWCJzhXac/m8m.J3.pezi', '2023-02-05 18:52:48', NULL, 2460, '1676646382', 1), (2, 'Mario', '$2y$10$JP1R1NHQtObxxpUH86/LuO8uSi6T.4SoTlk2TGFIpuyAFYkZMgQpu', '2023-02-13 10:15:34', NULL, 35, '1676276134', 0);