Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 369636

Summary: [DB] MetaDataManager - unchecked cast
Product: [Modeling] EMF Reporter: Ales Dolecek <ales_d>
Component: cdo.dbAssignee: Stefan Winkler <stefan>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3 CC: stefan, stepper
Version: 4.13   
Target Milestone: ---   
Hardware: PC   
OS: All   
Whiteboard:

Description Ales Dolecek CLA 2012-01-25 04:49:30 EST
Build Identifier: 

MetaDataManagerreadPackageUnits(Connection, long, long, monitor) expects that Object returned for CDODBSchema.PACKAGE_UNITS_ORIGINAL_TYPE is Integer.

On Oracle, however, is is BigDecimal. Instad of 

(Integer)values[1]
(Long)values[2]

you should use

((Number)values[1]).intValue()
((Number)values[2]).longValue()



Reproducible: Sometimes

Steps to Reproduce:
Happens when the underlying database represents INTEGER and LONG data types as Java classes other than Integer and Long.

Oracle, for example, represents all numbers as BigDecimal.
Comment 1 Eike Stepper CLA 2012-08-14 22:53:02 EDT
Moving all open issues to 4.2. Open bugs can be ported to 4.1 maintenance after they've been fixed in master.
Comment 2 Eike Stepper CLA 2013-06-29 12:18:52 EDT
We'll try to address open problems in 4.3 (master) first and then port fixes back to 4.2.
Comment 3 Eike Stepper CLA 2015-07-14 02:14:00 EDT
Moving all open bugzillas to 4.5.
Comment 4 Eike Stepper CLA 2016-07-31 00:57:02 EDT
Moving all unaddressed bugzillas to 4.6.
Comment 5 Eike Stepper CLA 2017-12-28 01:19:05 EST
Moving all open bugs to 4.7
Comment 6 Eike Stepper CLA 2019-11-08 02:07:08 EST
Moving all unresolved issues to version 4.8-
Comment 7 Eike Stepper CLA 2019-12-13 12:48:10 EST
Moving all unresolved issues to version 4.9
Comment 8 Eike Stepper CLA 2020-12-11 10:37:59 EST
Moving to 4.13.