Skip to content

Commit

Permalink
Update report-router.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
datajohnson committed Jun 3, 2024
1 parent c2a2d92 commit 2de68b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/src/routes/report-router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ reportRouter.post("/", async (req: Request, res: Response) => {
//console.log("SQL", dVal.toSQL());
//req.body.date = dVal.toISO();

req.body.createDate = knex.raw(`TO_TIMESTAMP("${dVal.toFormat("yyyy-MM-dd HH:mm:ss")}", "YYYY-MM-DD HH24:MI:SS")`);
req.body.createDate = knex.raw(`TO_TIMESTAMP('${dVal.toFormat("yyyy-MM-dd HH:mm:ss")}', 'YYYY-MM-DD HH24:MI:SS')`);
delete req.body.date;

console.log("INSERTING REPORT", req.body);
Expand Down

0 comments on commit 2de68b3

Please sign in to comment.