You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Danilo Tommasina <dt...@risksys.com> on 2004/02/18 11:37:55 UTC

Re: Does OJB inner join work with Oracle 8i

Hi,

did you set the correct platform in your connection descriptor?
in repository.xml, you should have attribute platform set to oracle)

cheers
danilo

> hi
> 
> I have 2 classes: one for department(HRDepartment) and
> another one for employer (HREmployer)
> 
> there is a 1:1 association with these 2 classes: 
> ----------------------------------------------------
> HRDepartment.manager : HREmployer
> ----------------------------------------------------
> 
> I try to use the manager's name to find his managed
> department:
> ----------------------------------------------------
> Criteria crit = new Criteria();
> crit.addEqualTo("manager.name", managerName);
> QueryByCriteria query = new
> QueryByCriteria(HRDepartment.class, crit);
> HRDepartment department = (HRDepartment)
> broker.getObjectByQuery(query);
> ----------------------------------------------------
> 
> the executed sql as: (spy.log)
> ----------------------------------------------------
> SELECT 
>   A0.FULL_NAME,A0.MANAGER_ID,A0.DEPT_NO,A0.TOP_DEPT
> FROM
>   HR_ORG A0
> INNER JOIN
>   HR_EMP A1 
> ON
>   A0.MANAGER_ID=A1.EMP_NO 
> WHERE
>   A1.NAME = 'michael'
> ----------------------------------------------------
> 
> but I caught an exception:
> ----------------------------------------------------
> java.sql.SQLException: ORA-00933: SQL...(message in
> chinese)
> //Oracle 8i doesnt support inner join, said in oracle
> forum. (is it ture?)
> ----------------------------------------------------
> 
> I use Oracle 8i and classes12.zip as driver
> does OJB inner join work with Oracle 8i?
> (had you tried such usage with Oracle 8i?)
> how to slove these problems?
> 
> thanks.
> 
> elvis
> 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail SpamGuard - Read only the mail you want.
> http://antispam.yahoo.com/tools
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
> 


-- 
Danilo Tommasina, Dipl. Ing. FH Telecom
Software Engineer
RCS Riskmanagement Concepts Systems AG
Technoparkstrasse 1
CH-8005 Zuerich
T: +41 1 445 29 08
dtommasina@risksys.com
www.risksys.com


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org