Unable to read error message when inserting withdb.insert().values()
Hey there, i am using visual studio code and am developing with nuxt3. I am trying to insert an object but I am getting an error message that is very difficult to read. Am I doing something wrong?
I have no idea what's wrong looking at this..
4 Replies
Okay so my bad, I had wrong types for the createdAt and updatedAt. The error is very complicated and my eyes just couldnt really focus.
In the schema I added
.defaultNow()
to them. Will updatedAt be updated on every edit to the row?
No, defaultNot is only for insertion
Pg doesn't have an
on update
clause
I think people use triggers for stuff like thistyty