Hi all, I have the following class declaration (pseudo code):
class DBObject private String name private Collection attributes class DBAttribute private String name private String value when I execute a query like the following (with PB API): Criteria c = new Criteria(); c.addEqualsTo("attributes.name", "Ale"); Query q = QueryFactory.newQuery(DBObject.class, c); the generated SQL statement is SELECT A0.NAME FROM DBOBJECT A0 JOIN DBATTRIBUTE A1 ON A0.NAME=A1.OWNER WHERE name = 'Ale'; where OWNER is the column used by OJB to maintain references between an object and its attributes as specified in the repository_user.xml. It seems OJB "forgets" to use the alias A1 to qualify the attribute name in the WHERE clause; since both tables have such attribute, the query fails (using name instead of A1.name is ambiguous). Is this a bug in OJB or am I doing something wrong? Thanks, Alessandro --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]