bun
bun copied to clipboard
fix: allow LIMIT 0 for SELECT queries
This PR enables the correct queries of form SELECT ... LIMIT 0
.
Before that, the limit-clause wasn't applied to the query.
Closes https://github.com/uptrace/bun/issues/801
The new tests fail for mssql
, I've checked and they also fail for current master. Given that there were no tests for the LIMIT
clause, I have a felling that the implementation for LIMIT
and/or OFFSET
is broken for mssql
.
If this is true, it might be a better idea to fix those in a separate PR.
UPD: this ticket seems related https://github.com/uptrace/bun/issues/811
@ygabuev this looks good, but I can't merge a PR that breaks the build....
The new tests fail for
mssql
, I've checked and they also fail for current master. Given that there were no tests for theLIMIT
clause, I have a felling that the implementation forLIMIT
and/orOFFSET
is broken formssql
.If this is true, it might be a better idea to fix those in a separate PR.
UPD: this ticket seems related #811
Hi, I just implemented a fix for that problem in #1009. Could you please test if this workaround fixes your problem?