Hey there guys,So basically the app I'm trying to make is way more suited for a relational database.I'm going back and trying to convert it. I've never actually used MySql before so I'm a stuck with the implementation of tables.With mongodb if you wanted a schema, you just had to put it there on the page like thishttps://imgur.com/a/cmjNhF1So of course being a dipshit who has never used sql this is my initial lazy rough drafthttps://imgur.com/a/ZvsR19QSo I know this is extremely wrong. But how would I do it right? I watched a video where somebody did something like this--------------------------var sql = "CREATE TABLE Users (UserID int,Username varchar(20),Password varchar(20),Icon varchar(255),PRIMARY KEY(UserID));"conn.query(sql, function (err, result) {if(err){ throw err; }console.log(' table created');});});-----------------------------------Would you need to do that for each table? I've seen some people use something like Workbench. Unfortunately the environment I'm using (AWS Cloud 9) doesn't support stuff like that. Any help would be appreciated
Submitted July 18, 2019 at 02:09AM by BlacklightBurgundy
No comments:
Post a Comment