Hi,
Following the example provided in the online documentation I've tried
getting the join working across 2 tables.
The table structures are
Table A
Col1,Col2,Col3
Table B
Col1,Col2,Col4
Col1 and Col2 form the primary key for both the tables.
The finder definition is
<finder>
<name>findForXXByYYZZ</name>
<query>,B
WHERE B.Col1 = A.Col1
AND B.Col2= A.Col2
AND A.Col2= {0}
AND A.Col1 = {1}
</query>
<order></order></finder>
The sql that I'd wanted the finder to produce was
SELECT A.Col1, A.Col2
FROM A,B
WHERE B.Col1 = A.Col1
AND B.Col2= A.Col2
AND A.Col2= {0}
AND A.Col1 = {1}
The sql produced, however, seems to be
SELECT A.Col1, Col2
FROM A,B
WHERE B.Col1 = A.Col1
AND B.Col2 = A.Col2
AND A.Col2= {0}
AND A.Col1 = {1}
Now Col2 is an ambiguous column and the query, obviously would fail.
Has anyone come across this and found a work around? Is anyone on the JBoss
Developers list working towards fixing this?
Please do let me know
Kind Regards
Vinay Menon
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user