You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Doing a Drizzle watched query as per the docs, but instead of db.select(), using db.query.findMany({ with: { someRelationName: true }}), will result in all relations being returned (1) as JSON and (2) as an array of arrays of object-values instead of just... an array of objects.
Am I tapping into an unsupported feature, or is this a bug?
The text was updated successfully, but these errors were encountered:
Hey @steveninety, I believe this is related to a known issue recently found with mapping the query to raw. Those relational queries depend on Drizzle to map the values back. We will be adding dedicated watch functions to both our Drizzle and Kysely packages to resolve this problem.
You can see a discord thread about it here.
A solution is in PR here, and should be available in the week.
Doing a Drizzle watched query as per the docs, but instead of
db.select()
, usingdb.query.findMany({ with: { someRelationName: true }})
, will result in all relations being returned (1) as JSON and (2) as an array of arrays of object-values instead of just... an array of objects.Am I tapping into an unsupported feature, or is this a bug?
The text was updated successfully, but these errors were encountered: