In 2013 according to @Timo Westkämper (see QueryDSL - add subquery into FROM statement) it was possible to include a subquery in a FROM clause. Nowadays it seems this is not longer possible as JPQL specification does not allow it:
(https://docs.oracle.com/cd/E12839_01/apirefs.1111/e13946/ejb3_langref.html#ejb3_langref_subqueries) Subqueries are restricted to the WHERE and HAVING clauses in this release. Support for subqueries in the FROM clause will be considered in a later release of the specification.
I don't get how is this possible. Can you confirm it's not possible to use subqueries in a FROM clause in querydsl 4.4.x?