· 5 years ago · Oct 30, 2020, 01:10 PM
1➜ referentiel-produit-api git:(develop) ✗ npm start
2
3> untitled1@0.0.0 start /Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api
4> nodemon ./bin/www
5
6[nodemon] 2.0.6
7[nodemon] to restart at any time, enter `rs`
8[nodemon] watching path(s): *.*
9[nodemon] watching extensions: js,mjs,json
10[nodemon] starting `node ./bin/www`
112020-10-30 2:00:50 [info]: Connection has been established successfully.
122020-10-30 2:00:50 [info]: The table for the User model was just (re)created!
132020-10-30 2:00:50 [info]: Connection has been established successfully.
142020-10-30 2:00:50 [info]: The table for the Client model was just (re)created!
152020-10-30 2:00:50 [info]: Connection has been established successfully.
162020-10-30 2:00:50 [info]: The table for the Product model was just (re)created!
17(node:17007) [SEQUELIZE0006] DeprecationWarning: This database engine version is not supported, please update your database server. More information https://github.com/sequelize/sequelize/blob/master/ENGINE.md
18(Use `node --trace-deprecation ...` to show where the warning was created)
192020-10-30 2:00:51 [verbose]: Executing (default): SELECT 1+1 AS result
202020-10-30 2:00:51 [verbose]: Executing (default): CREATE TABLE IF NOT EXISTS `Products` (`id` INTEGER NOT NULL auto_increment , `product-code` VARCHAR(255) NOT NULL, `product-family` VARCHAR(255), `product-description` VARCHAR(255), `min-quantity` INTEGER, `packaging` INTEGER, `price` FLOAT, `assortment-type` VARCHAR(255), PRIMARY KEY (`id`)) ENGINE=InnoDB;
212020-10-30 2:00:51 [verbose]: Executing (default): SELECT 1+1 AS result
222020-10-30 2:00:51 [verbose]: Executing (default): SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`;
232020-10-30 2:00:51 [verbose]: Executing (default): CREATE TABLE IF NOT EXISTS `Users` (`id` INTEGER NOT NULL auto_increment , `firstName` VARCHAR(255) NOT NULL, `lastName` VARCHAR(255), PRIMARY KEY (`id`)) ENGINE=InnoDB;
242020-10-30 2:00:51 [verbose]: Executing (default): SELECT 1+1 AS result
252020-10-30 2:00:51 [verbose]: Executing (default): CREATE TABLE IF NOT EXISTS `Clients` (`id` INTEGER NOT NULL auto_increment , `Nom` VARCHAR(255), `Prenom` VARCHAR(255) NOT NULL, `Credit` FLOAT, `Paiement` FLOAT, `Compte` VARCHAR(255), PRIMARY KEY (`id`)) ENGINE=InnoDB;
26DatabaseError [SequelizeDatabaseError]: (conn=95, no: 1054, SQLState: 42S22) Unknown column 'product-code' in 'field list'
27sql: SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`; - parameters:[]
28 at Query.formatError (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/sequelize/lib/dialects/mariadb/query.js:280:16)
29 at Query.run (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/sequelize/lib/dialects/mariadb/query.js:66:18)
30 at processTicksAndRejections (internal/process/task_queues.js:93:5)
31 at async /Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/sequelize/lib/sequelize.js:619:16
32 at async MySQLQueryInterface.select (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/sequelize/lib/dialects/abstract/query-interface.js:938:12)
33 at async Function.findAll (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/sequelize/lib/model.js:1753:21) {
34 parent: SqlError: (conn=95, no: 1054, SQLState: 42S22) Unknown column 'product-code' in 'field list'
35 sql: SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`; - parameters:[]
36 at Object.module.exports.createError (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/misc/errors.js:55:10)
37 at PacketNodeEncoded.readError (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet.js:484:19)
38 at Query.readResponsePacket (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/cmd/resultset.js:46:28)
39 at PacketInputStream.receivePacketBasic (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet-input-stream.js:104:9)
40 at PacketInputStream.onData (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet-input-stream.js:169:20)
41 at Socket.emit (events.js:314:20)
42 at addChunk (_stream_readable.js:303:12)
43 at readableAddChunk (_stream_readable.js:279:9)
44 at Socket.Readable.push (_stream_readable.js:218:10)
45 at TCP.onStreamRead (internal/stream_base_commons.js:188:23) {
46 fatal: false,
47 errno: 1054,
48 sqlState: '42S22',
49 code: 'ER_BAD_FIELD_ERROR',
50 sql: 'SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`;',
51 parameters: undefined
52 },
53 original: SqlError: (conn=95, no: 1054, SQLState: 42S22) Unknown column 'product-code' in 'field list'
54 sql: SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`; - parameters:[]
55 at Object.module.exports.createError (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/misc/errors.js:55:10)
56 at PacketNodeEncoded.readError (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet.js:484:19)
57 at Query.readResponsePacket (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/cmd/resultset.js:46:28)
58 at PacketInputStream.receivePacketBasic (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet-input-stream.js:104:9)
59 at PacketInputStream.onData (/Users/timothemalandain/Desktop/EPITA/ING2/URSI/referentiel-produit-api/node_modules/mariadb/lib/io/packet-input-stream.js:169:20)
60 at Socket.emit (events.js:314:20)
61 at addChunk (_stream_readable.js:303:12)
62 at readableAddChunk (_stream_readable.js:279:9)
63 at Socket.Readable.push (_stream_readable.js:218:10)
64 at TCP.onStreamRead (internal/stream_base_commons.js:188:23) {
65 fatal: false,
66 errno: 1054,
67 sqlState: '42S22',
68 code: 'ER_BAD_FIELD_ERROR',
69 sql: 'SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`;',
70 parameters: undefined
71 },
72 sql: 'SELECT `id`, `product-code`, `product-family`, `product-description`, `min-quantity`, `packaging`, `price`, `assortment-type` FROM `Products` AS `Product`;',
73 parameters: undefined
74}
752020-10-30 2:00:51 [verbose]: Executing (default): SHOW INDEX FROM `Products`
762020-10-30 2:00:51 [verbose]: Executing (default): SHOW INDEX FROM `Users`
772020-10-30 2:00:51 [verbose]: Executing (default): SHOW INDEX FROM `Clients`