Hi,

a criteria with path expressions like in the OJB queries reference guide 
example (http://db.apache.org/ojb/docu/guides/query.html#Query+by+Criteria) 
does not work for me with broker.deleteByQuery(q).
Using Microsoft SQL Server, the resulting statement of the example

Criteria crit = new Criteria();
crit.addEqualTo("productGroup.groupName", "Liquors");
Query q = QueryFactory.newQuery(Article.class, crit);

Collection results = broker.getCollectionByQuery(q);

results in the correct JOIN in the SELECT statement, but using:

broker.deleteByQuery(q);

results in a statement, where the path expression ist not expanded but the 
statement executed is something like

DELETE FROM Artikel WHERE KategorieName='Liquors'

but I expected something like

DELETE FROM Artikel WHERE Kategorie_Nr IN (SELECT Kategorie_Nr FROM Kategorien 
WHERE KategorieName='Liquors')

Any hints?

Mit freundlichen Grüßen
i.A. Bernd Längerich
-- 
www.actosoft.de - Key Solutions for Retail - 




++++ ac news ++++ Marktgeflüster ++++ ac news ++++ Marktgeflüster ++++
Smarter Fashion - neue Geschäftsmodelle und integrierte Lösungen 
für die Fashion Value Chain +++ Das Seminar am 12.09.2006 im 
Zeughaus Neuss +++ Weitere Infos unter:
www.microsoft.com/germany/events/fashion
__________________________________________________________________________________________
 
act'o-soft GmbH Informationssysteme * Enger Str. 12 * D-33824 Werther (Westf.)
Tel.: +49-5203-9744-40 * Fax: +49-5203-9744-41 * eMail: [EMAIL PROTECTED]
Sitz der Gesellschaft ist Werther (Westf.) * Amtsgericht Gütersloh * HRB 5242
Geschäftsführer: Christian Malachowski * Dipl.-Ing. Michael Schramm
___________________________________________________________________________________________
___________________________________________________________________________________________

This e-mail including any attachments may contain information that is legally 
privileged and
confidential. It constitutes non-public information intended to be conveyed 
only to the designated 
recipient(s). If you are not an intended recipient please delete this e-mail 
and any attachments 
and do not read, copy, or retransmit it and please notify act'o-soft GmbH by 
return mail, 
e-mail or at +49/5203/974440. 
The unauthorized use, dissemination, distribution or reproduction of this 
e-mail, including
attachments, is prohibited and may be unlawful.
___________________________________________________________________________________________





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to