From: Jiri C. <di...@ci...> - 2012-01-18 07:58:20
|
Hi *, I have a table: recreate table test ( base numeric(15,4), test1 computed by (base+base), test2 computed by (cast(base+base as numeric(15,4))), foo bigint, bar numeric(15,4) ); If I run the query: select rf.RDB$FIELD_NAME, f.RDB$FIELD_SCALE, f.RDB$FIELD_TYPE, f.RDB$FIELD_SUB_TYPE from RDB$RELATION_FIELDS rf inner join RDB$FIELDS f on (rf.RDB$FIELD_SOURCE = f.RDB$FIELD_NAME) where rf.RDB$RELATION_NAME = 'TEST' it reports: BASE -4 16 1 TEST1 -4 16 0 TEST2 -4 16 1 FOO 0 16 0 BAR -4 16 1 Why is rdb$field_sub_type for test1 column "0"? Then it looks like bigint. Checking the rdb$field_scale could be a solution, but is it then numeric or decimal? Firebird 2.5.1 Windows 64bit -- Jiri {x2} Cincura (x2develop.com founder) http://blog.cincura.net/ | http://www.ID3renamer.com |