Bugs item #676533, was opened at 2003-01-29 04:15 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=376685&aid=676533&group_id=22866
Category: JBossCMP Group: CVS HEAD Status: Open Resolution: None Priority: 5 Submitted By: Jeremy Boynes (jboynes) Assigned to: Jeremy Boynes (jboynes) Summary: Multistep IS NULL SQL incorrect Initial Comment: With the commerce test schema, the EJB-QL query SELECT OBJECT(l) FROM LineItem l WHERE l.order.billingAddress IS NULL generates the SQL SELECT DISTINCT t0_l.id FROM LINEITEMEJB t0_l, ORDER_DATA t1_l_order WHERE (t1_l_order.BILLING_ADDRESS IS NULL) AND (t1_l_order.BILLING_ADDRESS=t1_l_order.id) which results in an SQLException because there is no ID column in ORDER_DATA but in reality it is just totally messed up. ---------------------------------------------------------------------- >Comment By: Sacha Labourey (slaboure) Date: 2003-01-29 09:24 Message: Logged In: YES user_id=95900 I suspect this bug to occur in other situations as well and not strictly in this "multi-step" schema. Here is the situation: Given a EJB A, which builds a composite recursive datastructure, something like: setId(Long id) // The unique identifier of A getId() : Long setParent(A) getParent() : A setChildren(Collection ofAs) getChildren() : Collection If you want to query all A's, which do not have a parent: SELECT OBJECT(a) FROM A a WHERE a.parent IS NULL Executing this EJB-QL i always get an empty collection. The SQL, which is generated is something like: SELECT t0_a.id FROM A t0_a WHERE (t0_a.parent IS NULL) AND (t0_a.parent=t0_a.id) which is wrong in this case. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=376685&aid=676533&group_id=22866 ------------------------------------------------------- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development