Hi Stephen,
As a first tip, use the newest JDBC driver available. I got in trouble with
classes12.zip
connecting a 9i Oracle instance. Look at Technet.
Best regards,
Daniel.
--- Stephen Kowalczyk <[EMAIL PROTECTED]> wrote:
> I'm having some trouble with Oracle, Criteria and table joins. My code works fine
>against
> mysql, but when I try to use Oracle I get an exception. This is using the newly
>released Torque
> 3.0 against Oracle 9 using the classes12.zip thin driver.
>
> In my code, I create a criteria:
>
> CRITERIA.addSelectColumn(RegistrationPeer.REGISTRATIONID);
> CRITERIA.addSelectColumn(AuthMapPeer.PARTNUMBER);
> CRITERIA.addJoin(RegistrationPeer.AUTHCODE, AuthMapPeer.AUTHCODE);
>
> Then I use the BasePeer to retrieve results and loop over them:
>
> List resultList = BasePeer.doSelect(CRITERIA);
>
> for (int i=0; i<resultList.size(); i++) {
> Record row = (Record) resultList.get(i);
> row.getValue(RegistrationPeer.REGISTRATIONID)
> }
>
> This code throw an exception:
>
> com.workingdogs.village.DataSetException: Column name: REGISTRATIONID does not exist!
>
> The value of RegistrationPeer.REGISTRATIONID is "Registration.REGISTRATIONID".
>Looking at the
> schema from
> row.schema(), I see that the column name is "REGISTRATIONID" (no tablename appended).
>
> I'm guessing that either I need to configure Oracle somehow or use the criteria/join
> differently. That, or the com.workingdogs.village stuff has a bug.
>
> Anyone have any suggestions/ideas?
>
> Thanks,
>
> Stephen
>
>
>
=====
-----------------------------------------
Daniel H. F. e Silva
Analista de Sistemas
SBPI
__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>