ObjectDB ObjectDB

Issue #798: Problem with JOIN and inheritance

Type: Bug ReoprtVersion: 2.3.7Priority: NormalStatus: ClosedReplies: 1
#1

Hello,

Please run this query on the attached DB:

SELECT DISTINCT $1 FROM com.quasado.serviceplaza.customer.VendorCustomer $1 JOIN $1.qubletFRAGMENTMAP $2, com.quasado.foundation.warehouse.contract.customer.CustomerContractsFragment $3 WHERE ((NOT (($2=$3) AND ($3.contracts IS EMPTY))))

The problem is quite easy: The "VendorCustomer" class inherits from the "Customer" class.

Now with this query I do select from "VendorCustomer" yet through using the join, he is also selecting all "Customer" classes which fullfill the where requirements. This seems to be clearly wrong to me because I should not even join the $1.qubletFRAGMENTMAP of any other class but "VendorCustomer"!?

thanks

Alex

edit
delete
#2

My bad, 2.4.0 seems to fix it.

edit
delete

Reply

To post on this website please sign in.