Why jsonArrayFrom converts a Generated<number> field into string | number?

Look at this pic
No description
Solution:
Since you're not using table specifiers, are you sure some "parent" table doesn't also have those columns and you are actually selecting them?
Jump to solution
5 Replies
thelinuxlich
thelinuxlich13mo ago
using a $castTo solves it, but I'd like to understand the behavior
No description
thelinuxlich
thelinuxlich13mo ago
another weird type change, here country and state aren't nullable but jsonObjectFrom changes them:
No description
Solution
koskimas
koskimas12mo ago
Since you're not using table specifiers, are you sure some "parent" table doesn't also have those columns and you are actually selecting them?
koskimas
koskimas12mo ago
It's much easier to help if you provide a playground or even the full code as a text
thelinuxlich
thelinuxlich12mo ago
you nailed it, I feel so dumb! thanks a lot @koskimas
Want results from more Discord servers?
Add your server