Open jamesopstad opened 5 months ago
What version of pg / pg-types are you using? This should have been fixed in https://github.com/brianc/node-pg-types/commit/afead5b156c179364d173965bae2d661beb2230f and there are tests in the repo for that as well:
I am seeing this behaviour in the latest version of pg
(8.11.3). Looking at its dependencies though, I see that it is using an old version of pg-types
(2.1.0). Apologies, I assumed they would be updated together. Should I raise an issue in the node-postgres repo instead?
Yes it needs to be updated in pg
. Check if there's an existing issue as IIRC this has come up previously and if not open an issue. There's some (potentially?) breaking changes that would mandate a major version bump on the pg
side to incorporate the newer version of this library but after five years it's probably time we do it.
I've come across an issue where numeric values are parsed as strings but arrays of numerics are parsed as number arrays. Here is a minimal query to reproduce:
I would expect numeric arrays to parse as string arrays.