Subject [IBO] Re: is 0.208 some magic value ? (3th post)
Author duilio_f
Jason,

your suggestion worked.

For the record, I commented out the enclosed code in IBDataset.pas.

Thank you

Duilio Foschi


procedure GetDataTypeAndSize( ACol: TIB_Column;
var NewDataType: TFieldType;
var NewDataSize: integer;
var BoolList: boolean );
begin
NewDataType := ftUnknown;
NewDataSize := 0;
if Assigned( ACol ) then
with ACol do
begin
if IsBoolean and
(((( SQLtype = SQL_SHORT ) or
( SQLtype = SQL_SHORT_ ) or
( SQLtype = SQL_LONG ) or
( SQLtype = SQL_LONG_ ) or
( SQLtype = SQL_QUAD ) or
( SQLtype = SQL_QUAD_ ) or
( SQLtype = SQL_INT64 ) or
( SQLtype = SQL_INT64_ ) or
( SQLtype = SQL_FLOAT ) or
( SQLtype = SQL_FLOAT_ ) or
( SQLtype = SQL_DOUBLE ) or
( SQLtype = SQL_DOUBLE_ )) and ( BooleanTrue =
BoolTrueNbr ) and
( BooleanFalse =
BoolFalseNbr ) and
( SQLScale = 0 )) or
( SQLtype = SQL_TEXT ) or
( SQLtype = SQL_TEXT_ ) or
( SQLtype = SQL_VARYING ) or
( SQLtype = SQL_VARYING_ )) then
begin
NewDataType := ftBoolean;
BoolList := BoolList or
( ACol.BooleanTrue <> BoolTrueChr ) or
( ACol.BooleanFalse <> BoolFalseChr ) or
( SQLLen <> 1 );
end
else
if SQLScale <> 0 then
begin
NewDataType := ftFloat;
// the following code was commented out
(*
case SQLType of
SQL_FLOAT,
SQL_FLOAT_,
SQL_DOUBLE,
SQL_DOUBLE_: ;
else
if ( SQLScale >= -4 ) and not IsAttributeSet[ 'NOBCD' ] then
begin
NewDataType := ftBCD;
NewDataSize := 8;
end;
end;
*)
// up to here
end
else
<cut>



At 08.06 12/04/02 -0000, you wrote:
>--- In IBObjects@y..., "Jason Wharton" <jwharton@i...> wrote:
>How about you set the ColumnAttribute NOBCD or for that matter
>temporarily
>alter the code to make it so that IBO will not use the BCD field
type
>and
>see if that will work. I have had so many tussles with BCD columns
>because
>Borland changes things every single version of Delphi...
>
>Jason Wharton
>CPS - Mesa AZ
>http://www.ibobjects.com
>--- End forwarded message ---
>
>
>