Home » Eclipse Projects » EclipseLink » left side of the IN operator missing?
left side of the IN operator missing? [message #377457] |
Mon, 04 August 2008 14:20 |
Tom Eugelink Messages: 825 Registered: July 2009 |
Senior Member |
|
|
I have a JPQL query that looks like this:
select sol from Sellorderline sol where sol.iArticle in (select a from License l inner join l.iLicenseArticlesWhereIAmLicense la inner join la.iArticle a where l = :license)
It tries to find Sellorderlines where the article that is sold is present in the specified license. The generated SQL looks like this (I've stripped some of the returned fields):
SELECT t1.sellorderlinenr, t1.articlenr, ...,t1.dwhby FROM article t0, sellorderline t1 WHERE ( IN (SELECT DISTINCT t2.articlenr, t2.articletypenr, t2.description, t2.sellingprice, t2.length, t2.width, t2.inserted, t2.std_reservation, t2.haslicenses, t2.minimalstock, t2.is_landscape, t2.actueel, t2.weight, t2.c, t2.f, t2.info, t2.rolinstellingenok, t2.rolkop, t2.tapper, t2.veer, t2.lazylock, t2.managestock, t2.seqnr, t2.keywords, t2.opweb, t2.dwhmodified, t2.dwhby, t2.ean, t2.opwebdate, t2.salestatus FROM license t4, license_article t3, article t2 WHERE ((? = t4.licensenr) AND ((t3.licensenr = t4.licensenr) AND (t2.articlenr = t3.articlenr)))) AND (t0.articlenr = t1.articlenr))
Note the "WHERE ( IN (SELECT"; the left side of the IN is not present! Am I doing something wrong?
Tom
|
|
| | | |
Goto Forum:
Current Time: Wed Sep 25 12:17:29 GMT 2024
Powered by FUDForum. Page generated in 0.03145 seconds
|