Excuse me if this is too simple to post hereI'm trying to make a database table with the following variables. Again, i'm sorry if you feel as though i'm wasting your time I just didn't know where else to go for helpvar mysql = require(mysql); var con = mysql.createConnection({ host: "localhost", user: "user", password: "password" }); con.connect(function(err) { if (err) throw err; console.log("Connected!"); var sql = "CREATE TABLE items (number VARCHAR(50) DEFAULT NULL, snumber VARCHAR(50) DEFAULT NULL, itemtype VARCHAR(50) DEFAULT NULL, itemshape VARCHAR(50) DEFAULT NULL, itemcolor VARCHAR(50) DEFAULT NULL, itemcountry VARCHAR(50) DEFAULT NULL, enhcode VARCHAR(50) DEFAULT NULL, quality VARCHAR(50) DEFAULT NULL, misc VARCHAR(80) DEFAULT NULL, desc VARCHAR(255) DEFAULT NULL, qt DECIMAL(10,0) DEFAULT NULL, wt DECIMAL(10,2) DEFAULT NULL, cost DECIMAL(18,2) DEFAULT NULL, price1 DECIMAL(18,2) DEFAULT NULL, price2 DECIMAL(18,2) DEFAULT NULL, price3 DECIMAL(18,2) DEFAULT NULL, certnumber VARCHAR(100) DEFAULT NULL, itemlab VARCHAR(50) DEFAULT NULL, itemvar VARCHAR(50) DEFAULT NULL, itemtrans VARCHAR(50) DEFAULT NULL, itemspec VARCHAR(50) DEFAULT NULL, enhacement VARCHAR(200) DEFAULT NULL, cut VARCHAR(200) DEFAULT NULL, comments VARCHAR(255) DEFAULT NULL, length DOUBLE DEFAULT NULL, width DOUBLE DEFAULT NULL, depth DOUBLE DEFAULT NULL, dime VARCHAR(200) DEFAULT NULL, mqt DECIMAL(10,0) DEFAULT NULL, mwt DECIMAL(10,2) DEFAULT NULL, idn BIGINT(20) DEFAULT NULL, sidn BIGINT(20) DEFAULT NULL, image1 VARCHAR(200) DEFAULT NULL, image2 VARCHAR(200) DEFAULT NULL, image1_1 VARCHAR(200) DEFAULT NULL, image1_2 VARCHAR(200) DEFAULT NULL, image1_3 VARCHAR(200) DEFAULT NULL, image1_4 VARCHAR(200) DEFAULT NULL, image1_5 VARCHAR(200) DEFAULT NULL, image1_6 VARCHAR(200) DEFAULT NULL, image1_7 VARCHAR(200) DEFAULT NULL, image1_8 VARCHAR(200) DEFAULT NULL, image1_9 VARCHAR(200) DEFAULT NULL, image1_10 VARCHAR(200) DEFAULT NULL, cert VARCHAR(10) DEFAULT NULL, pair VARCHAR(10) DEFAULT NULL, UploadInProgress TINYINT(1) DEFAULT NULL, id INT(11) NOT NULL AUTO_INCREMENT, PRIMARY KEY ('id')) ENGINE=MyISAM AUTO_INCREMENT=545405 DEFAULT CHARSET=utf8"; con.query(sql, function (err, result) { if (err) throw err; console.log("Table created"); }); }); This is the error that I can't seem to resolve
Submitted May 16, 2019 at 02:52PM by brilliantmojo
No comments:
Post a Comment