Return-Path: Mailing-List: contact ojb-dev-help@db.apache.org; run by ezmlm Delivered-To: mailing list ojb-dev@db.apache.org Received: (qmail 56573 invoked from network); 8 Apr 2003 19:09:06 -0000 Received: from mail.gmx.net (213.165.65.60) by daedalus.apache.org with SMTP; 8 Apr 2003 19:09:06 -0000 Received: (qmail 20362 invoked by uid 65534); 8 Apr 2003 19:09:07 -0000 Received: from adsl-62-167-198-154.adslplus.ch (EHLO gmx.ch) (62.167.198.154) by mail.gmx.net (mp009-rz3) with SMTP; 08 Apr 2003 21:09:07 +0200 Message-ID: <3E931E42.8080607@gmx.ch> Date: Tue, 08 Apr 2003 21:08:50 +0200 From: Jakob Braeuchi User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en MIME-Version: 1.0 To: OJB Developers List Subject: Re: query for extents joining with null table References: <1049810445.5078.35.camel@zacarias> <3E92F406.1010302@gmx.ch> <1049822021.5076.112.camel@zacarias> <3E930447.9080002@gmx.ch> <1049826494.6403.172.camel@zacarias> <3E93178D.5030608@gmx.ch> In-Reply-To: <3E93178D.5030608@gmx.ch> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N checked it in Jakob Braeuchi wrote: > i'll do additional test and in case everything goes fine i'll check it in > > jakob > > Leandro Rodrigo Saad Cruz wrote: > >> Yes.... it doesn't uses null for table names anymore ! >> >> thanx... >> >> On Tue, 2003-04-08 at 14:17, Jakob Braeuchi wrote: >> >> >>> hi leandro, >>> >>> i think i already have one: >>> >>> modifiy the collection descriptor of ProductGroup in >>> repository_junit.xml to point to AbstractArticle: >>> >>> >> name="allArticlesInGroup" >>> element-class-ref="org.apache.ojb.broker.AbstractArticle" >>> auto-retrieve="true" >>> auto-update="true" >>> auto-delete="false" >>> > >>> >>> that results in a NULL table. >>> >>> jakob >>> >>> Leandro Rodrigo Saad Cruz wrote: >>> >>> >>> >>>> I'll try to write a test case for this ! >>>> >>>> On Tue, 2003-04-08 at 13:08, Jakob Braeuchi wrote: >>>> >>>> >>>> >>>> >>>>> hi leandro, >>>>> >>>>> could you please send me the java-classes, repository and the sql >>>>> to create the necessary tables ? >>>>> >>>>> jakob >>>>> >>>>> Leandro Rodrigo Saad Cruz wrote: >>>>> >>>>> >>>>> >>>>> >>>>>> Hi Jacob ! >>>>>> >>>>>> I'm upgrading from 0.9.8 to 1.0.rc2 an I got this problem : >>>>>> >>>>>> _________________ ________________ >>>>>> | | | | >>>>>> | AbstractClassA |1---*| AbstractClassB | >>>>>> |________________| |________________| >>>>>> ^ ^ >>>>>> | | >>>>>> ------------- --------------- | | >>>>>> | | >>>>>> ____ ____ ____ ____ >>>>>> | | | | | | | | >>>>>> | A1 | | A2 | | B1 | | B2 | >>>>>> |____| |____| |____| |____| >>>>>> >>>>>> >>>>>> When I use OJB like this : >>>>>> >>>>>> >>>>>> Criteria crit = new Criteria() >>>>>> crit.addEqualTo("allBs.name",someName) >>>>>> QueryByCriteria query = new >>>>>> QueryByCriteria(AbstractClassA.class,crit); >>>>>> Collection result = broker.gteCollectionByQuery(query) >>>>>> >>>>>> >>>>>> I get an error because ojb is joinning with three tables >>>>>> AbstractClassB - NO TABLE >>>>>> B1 - TABLE_B_1 >>>>>> B2 - TABLE_B_2 >>>>>> >>>>>> >>>>>> SELECT * >>>>>> >>>>>> FROM TABLE_A_1 A0 INNER JOIN ((((((TABLE_A_VERSUS_B A1 INNER JOIN >>>>>> null >>>>> >>>>> >>>>> >>>>> >>>>>> A2 ON A1.AID_ID=A2.AID) LEFT OUTER JOIN TABLE_B_1 A2E1 ON >>>>>> A1.AID=A2E1.ID) LEFT OUTER JOIN TABLE_B_2 A2E2 ON ... >>>>>> >>>>>> >>>>>> We are trying to join with the table that AbstractClassB should >>>>>> have, >>>>>> but it doesn't ! I looked at SqlQueryStatement.java and I'm not sure >>>>>> where I have to make modifications for this to work. >>>>>> >>>>>> When I first implemented extent aware path expressions I put a log >>>>>> warning (see createTableAlias(ClassDescriptor cld, String path)) >>>>>> about >>>>>> abstract classes, but I think there is not place anymore where we >>>>>> check >>>>>> for this ! >>>>>> >>>>>> Can you help me solve this problem ! >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>> >>>>> --------------------------------------------------------------------- >>>>> To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org >>>>> For additional commands, e-mail: ojb-dev-help@db.apache.org >>>>> >>>>> >>>>> >>>>> >>>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org >>> For additional commands, e-mail: ojb-dev-help@db.apache.org >>> >>> >>> >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org > For additional commands, e-mail: ojb-dev-help@db.apache.org > >