lorentz
how to union two queries with json_build_object?
i would like to union two queries to get a result of type
QueryA | QueryB
. this query fails the type checker but the generated query seems to work as intended. is there a type hint i can provide somehow?
https://kyse.link/2TBLF10 replies
how to decode a point to `{x: number, y: number}` when selected inside `jsonBuildObject`?
when i select a column of type point the basic way i get it decoded to
{x: number, y: number}
, but when i wrap it in jsonBuildObject
i get it as the raw string.
example:
12 replies
are conditional CTEs possible?
i don't find any hints here https://kysely.dev/docs/category/cte.
i have tried the conditional where approach (https://kysely.dev/docs/examples/WHERE/conditional-where-calls), but i get type error
Type 'QueryCreatorWithCommonTableExpression ... The types returned by 'with(...)' are incompatible between these types.
5 replies