SQL : Union for subqueries

Bug #603575 reported by Timo Westkämper on 2010-07-09
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Querydsl
Fix Released
Undecided
Unassigned

Bug Description

I would like to use the union as a subquery and join against it. It would be good if union returned the query.

        ... = query.from(table1).leftJoin(subquery.union(
                sq().unique(one.as(col1)),
                sq().unique(two),
                sq().unique(three)), sq)
            .on(table1.col1.eq(sq.get(col1)))
            .where(sq.get(col1).isNull())

This is very useful for comparing user input to existing values in a set-based way to generate insert statements.

Changed in querydsl:
status: New → Fix Committed

Released in 1.8.0

Changed in querydsl:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers