I think eb should be ExpressionBuilder<Database, never> but instead it's ExpressionBuilder<Database, keyof Database>.
I might be brainfarting here but ExpressionBuilder<Database, keyof Database> is saying "we've joined every table in the database to this query. Go nuts!".
The reproduction fails because there are two tables with different id type "joined" to the query.
Reprodution https://kyse.link/HqeCE
I think
eb
should beExpressionBuilder<Database, never>
but instead it'sExpressionBuilder<Database, keyof Database>
.I might be brainfarting here but
ExpressionBuilder<Database, keyof Database>
is saying "we've joined every table in the database to this query. Go nuts!".The reproduction fails because there are two tables with different
id
type "joined" to the query.