Issue Details (XML | Word | Printable)

Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Andy Jefferson
Reporter: Andy Jefferson
Votes: 0
Watchers: 0

If you were logged in you would be able to see more operations.
DataNucleus Store RDBMS

RDBMSStoreManager.getClassNameForObjectID sometimes chooses UNION when discriminator defined!

Created: 02/Apr/10 10:32 AM   Updated: 26/Apr/10 03:38 PM   Resolved: 07/Apr/10 02:45 PM
Component/s: Queries
Affects Version/s: None
Fix Version/s: 2.1.0.m2

File Attachments: 1. Zip Archive (8 kB)

 Description  « Hide
If we have

Base (new-table)
AbstractSub (new-table) Sub2 (superclass-table)
Sub1 (superclass-table)

then when call pm.getObjectById for an id for the Base class this goes via a UNION query, even though Base has a discriminator defined!

It finds the correct class, but ought to use a simple discriminator query on the BASE table

Andy Jefferson made changes - 02/Apr/10 10:32 AM
Field Original Value New Value
Attachment [ 11121 ]
Andy Jefferson added a comment - 07/Apr/10 02:45 PM
RDBMSStoreManager.getClassNameForObjectID has been rewritten in SVN trunk to handle this case (and all other cases tested by DN unit tests and JDO TCK)

Andy Jefferson made changes - 07/Apr/10 02:45 PM
Status Open [ 1 ] Resolved [ 5 ]
Assignee Andy Jefferson [ andy ]
Fix Version/s 2.1.0.m2 [ 10912 ]
Fix Version/s 2.1.0.release [ 10832 ]
Resolution Fixed [ 1 ]
Andy Jefferson made changes - 26/Apr/10 03:38 PM
Status Resolved [ 5 ] Closed [ 6 ]