View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0000478||Database Workbench v4||Oracle Module||public||2012-10-18 10:45||2013-01-22 12:34|
|Reporter||Dave Sellers||Assigned To||Martijn Tonies|
|Fixed in Version||4.4.0|
|Summary||0000478: INTEGER becomes NUMBER (floating point) but should be NUMBER(38)|
|Description||If you edit a table structure and create a column (or alter an existing column) and set the type to Integer, DBW will produce the DDL e.g.|
ALTER TABLE AC_DOCUMENTS
whether you let DBW modify the table or run that script separately, what it produces is a column of type Number (no length, scale 0) which is actually a floating point column, not an integer at all.
|Steps To Reproduce||See above|
|Additional Information||Not sure whether the problem is Oracle which seems to accept Integer as a type in DDL and then produces something that seems (to me) to be completely different. It might be less confusing if DBW didn't offer Integer as a type as this would force the user to be more explicit about what they actually need/want.|
|Tags||No tags attached.|
|DBMS & Version|
An Oracle NUMBER without scale is an INTEGER, Oracle accepts "Integer" as a type alias, see:
DBW offers this as an easy method of datatype input.
||Oh wait, I might have misread something here, it seems INTEGER results in NUMBER without the "precision" specifier, this seems wrong indeed.|
Glad I'm not going mad. I updated about 30 oracles schemas last night only to find that Delphi application freaked with TIntegerField persistent fields now pointing at Floats...
Yes, I did test first. Well, sort of, the one I tested I manually changed the scale from 2 to 6 which fixed the original problem (don't ask why anyone would create a 2 digit wide column, it wasn't me!). Then I thought "why limit to 6, that's just a time-bomb waiting to go off in the future?" so I changed to Integer which was a time-bomb with a much shorter fuse;-)
No real harm done (apart to my nerves!) and another lesson learned.
Well, I'm not sure what INTEGER in Oracle gets you for a TField in Delphi. ;)
All I know is that INTEGER is the same as NUMBER(38) and DBW should show either INTEGER or NUMBER(38) if you use INTEGER.
|2012-10-18 10:45||Dave Sellers||New Issue|
|2012-10-18 11:40||Martijn Tonies||Note Added: 0000138|
|2012-10-18 11:40||Martijn Tonies||Status||new => feedback|
|2012-10-18 11:52||Martijn Tonies||Note Added: 0000139|
|2012-10-18 11:58||Martijn Tonies||Status||feedback => confirmed|
|2012-10-18 11:59||Martijn Tonies||Summary||Column type conversion => INTEGER becomes NUMBER (floating point) but should be NUMBER(38)|
|2012-10-18 12:11||Dave Sellers||Note Added: 0000140|
|2012-10-18 12:14||Martijn Tonies||Note Added: 0000141|
|2012-10-19 10:47||Martijn Tonies||Assigned To||=> Martijn Tonies|
|2012-10-19 10:47||Martijn Tonies||Status||confirmed => assigned|
|2012-10-24 11:48||Martijn Tonies||Status||assigned => resolved|
|2012-10-24 11:48||Martijn Tonies||Fixed in Version||=> 4.3.2|
|2012-10-24 11:48||Martijn Tonies||Resolution||open => fixed|
|2013-01-22 12:34||Martijn Tonies||Status||resolved => closed|