Merge branch 'main' into mannBranch

This commit is contained in:
Mann Patel
2025-03-22 14:19:38 -06:00
2 changed files with 6 additions and 4 deletions

View File

@@ -36,6 +36,7 @@ CREATE TABLE Product (
StockQuantity INT,
UserID INT,
Description TEXT,
Timestamp DATETIME DEFAULT CURRENT_TIMESTAMP,
CategoryID INT NOT NULL,
Date DATETIME DEFAULT CURRENT_TIMESTAMP,
FOREIGN KEY (UserID) REFERENCES User (UserID),

View File

@@ -2,10 +2,11 @@ const mysql = require("mysql2");
//Create a pool of connections to allow multiple query happen at the same time
const pool = mysql.createPool({
host: "localhost",
user: "root",
database: "marketplace",
password: "12345678",
host: "marketplace-db.cpkkqmq065sx.ca-central-1.rds.amazonaws.com",
user: "admin",
password: "qizsYh-movpub-wuhdo2",
database: "Marketplace",
port: "3306",
});
//Export a promise for promise-based query