Ah sorry, it is probably related to Cayenne (the rownum wrapper)... my bad... Could you post a Cayenne code that you are using to initiate this query?
Andrus On Jun 2, 2011, at 3:34 PM, Andrus Adamchik wrote: > This is clearly an Oracle SQL syntax error, nothing to do with Cayenne. I > don't have a handy Oracle install to try it out. But maybe somebody else here > with more recent Oracle experience can spot the issue? Otherwise you may try > the Oracle forums. > > Andrus > > > On Jun 2, 2011, at 3:19 PM, Bruno René Santos wrote: >> Here it goes again... Please can anybody help? >> >> Thanx >> Bruno >> >> Em 31-05-2011 15:43, Bruno René Santos escreveu: >>> Hello all, >>> >>> >>> I am having a problem with the setFetchLimit on Oracle. When I use >>> joined tables that have fields with the same name i get the error: >>> >>> Error code 918, SQL state 42000: ORA-00918: column ambiguously defined >>> >>> with a query similar to the next one: >>> >>> select * from ( select tid.*, ROWNUM rnum from ( >>> SELECT .... LEFT JOIN >>> ENTIDADE t1 ON (t0.ENTIDADE_ID_ENTIDADE = t1.ID_ENTIDADE) WHERE >>> t0.FISC_ID_FISCALIZACAO = 6103 ORDER BY t0.DT_AVERIG) >>> tid where ROWNUM<=15) where rnum> 0 >>> >>> Any way around this? >>> >>> Thanx >>> Bruno >>> >>> >> >> >> -- >> Bruno René Santos | [email protected]<mailto:[email protected]> | >> Gestor de Projectos | Analista | Programador | Investigador >> >> Holos - Soluções Avançadas em Tecnologias de Informação S.A. >> Parque de Ciência e Tecnologia de Almada/Setúbal . Edifício Madan Parque >> Rua dos Inventores . Quinta da Torre . 2825 - 182 Caparica . Portugal >> Phone: +351 210 438 686 . Fax: +351 210 438 687 . Web: www.holos.pt >> >> >> This email and any files transmitted with it are confidential and >> intended solely for the use of the individual or entity to whom they are >> addressed. If you are not the intended recipient or the person >> responsible for delivering the email to the intended recipient, be >> advised that you have received this email in error and that any use, >> dissemination, forwarding, printing, or copying of this email is >> strictly prohibited. If you have received this email in error please >> notify Bruno René Santos by telephone on +351 210 438 686 >> >> >> >> > >
