drizzle-team / drizzle-team/drizzle-orm
[FEATURE]: Multiple union / unionAll
Open
enhancement
qb/crud
qb/set-operators
- Dominant language
- TypeScript
- Stars
- 35.8k
- Forks
- 1.6k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 4
Description
### Describe what you want
Currently only 2 queries are corretly combined to a union.
When you add a third query, the first two are wrapped with () and all wrapped too, that doesn't work.
Example (current result of drizzle), when `unionAll(query1, query2, query3)`
```
(
(
SELECT ...
)
UNION ALL
(
SELECT ...
)
)
UNION ALL
(
SELECT ...
)
```
Contributor guide
Assessment
This issue has not been assessed yet.