error log
ERROR: invalid input syntax for type integer: "NaN"
err: {
"type": "DatabaseError",
"message": "invalid input syntax for type integer: "NaN"",
"stack":
error: invalid input syntax for type integer: "NaN"
at C:\admin\node_modules\pg-pool\index.js:45:11
at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
at async eval (webpack-internal:///(rsc)/./node_modules/drizzle-orm/node-postgres/session.js:96:22)
....
"length": 146,
"name": "error",
"severity": "ERROR",
"code": "22P02",
"where": "unnamed portal parameter $1 = '...'",
"file": "numutils.c",
"line": "619",
"routine": "pg_strtoint32_safe"
}
I am also on payload 3.17.1 and also getting the an error on versions compare. However my devtools show a 404 instead of a 500 error. This is the 404 query
/api/patients/versions?depth=0&limit=10&page=1&where%5Band%5D%5B0%5D%5Bid%5D%5Bnot_equals%5D=678a32e6b610eddb2084ae7b&where%5Band%5D%5B1%5D%5Bparent%5D%5Bequals%5D=678a32d9b610eddb2084ae61. I'm have not set any access restrictions on the versions. Both the parent Id and version ID in this query seem ok. There are 4 other versions listed in the admin UI. Not sure how I can fix this at this point. Thank you.
usually should not be 404, not sure whether you have set any base url in the payload config, double check whether it match the url of your admin portal in the browser
hi. thanks. yes it does. the full URL is still the default dev one actually:
http://localhost:3000/api/patients/versions?depth=0&limit=10&page=1&where%5Band%5D%5B0%5D%5Bid%5D%5Bnot_equals%5D=678a477cb610eddb2084b704&where%5Band%5D%5B1%5D%5Bparent%5D%5Bequals%5D=678a330cb610eddb2084aed7newer version of payload cms is released, i think it will fix the versioning route issue, you can check it out
Hi. Yes ! Just tried the new version and now the 404 is gone. And I can select a version to compare against. However, the version name (in the version dropdown select) remains to "Loading..." . This is probably just a UI bug, since I can select a random version and the diff shows.
I reinstalled a fresh payload instance and now the "loading..." state is gone. Maybe my upgrade process went wrong or something was in the data. I consider my issue fixed 🎉 .
@474772813706821652feel free to mark your issue as resolved if it is also resolved for you.
run /solve
Star
Discord
online
Get dedicated engineering support directly from the Payload team.