Subject Re: [IBO] Strange TFieldTypes
Author Rohit Gupta
----- Original Message -----
From: "Jason Wharton" <jwharton@...>
To: <IBObjects@yahoogroups.com>
Sent: Wednesday, 21 February 2001 19:00
Subject: Re: [IBO] Strange TFieldTypes


> My apologies for this. I have someone who is in the middle of a very large
> BDE to IBO conversion and I am trying to make things overall more
flexible.
> It really is a challenge.
>
> I don't understand why you are having these two problems that well. I
wonder
> if your packages are properly rebuilt after applying source changes?


Thats never a problem, with Delfi's inability to keep track of file changes
and NTs ability to change the file size without changing its modification
date, we regularly delete all dcus and rebuild everything. Infact I know of
people who have added a menu option to the IDE to delete all dcus :-)

Problem # 1 - This kicked in once we had gone system wide and changed all
primary keys for 74 odd tables from longint to int64 and made various other
changes. After that the emulated bug kicks in on openeing the form and
insists on converting most fields to largeint.... no matter what you do.
The only solution is to delete all persistent fields anf lose all formating
and linking info and events and to recreate them.... but then, as soon as
there is an error, all fields again want to become largeints again. If you
look at that code - on error a numeric with a scale is being foeced to
largeint.... madness. The best solution was to remove the bug.

Problem # 2 - This is really a problem with Borlands stupidity. They said
they had implemented int64, which is why we reorganised the database to use
them..... then we find that Variants dont support it, Borland blame
Microsoft (amazing), TFIeld doesnt support it etc etc... Which means all
setrange, findkey, locate etc that use an int64 field just fail.

The not so obvious problems lurked in the lookup fields defined in the
tables.

The other not so obvious problem is the type integer. Anyone that has been
beta testing Pascal and Delphi would remember that when Borland changed the
meaning of integer from 2 bytes to 4 despite universal protest, they
promised that type integer would now always reflect the widest word
supported.... well, int64 has fallen through the cracks..... so everything
using integer fails.

Aargh, I would cheerfully throttle the person at Borland that decided to
implement a half-a...d solution for int64.

>
> Please let me know and keep me updated.
>
> Regards,
> Jason Wharton
> CPS - Mesa AZ
> http://www.ibobjects.com
>
>
> ----- Original Message -----
> From: "Rohit Gupta" <rohit@...>
> To: <IBObjects@yahoogroups.com>
> Sent: Friday, February 16, 2001 3:22 AM
> Subject: Re: [IBO] Strange TFieldTypes
>
>
> > In 3.6cf
> >
> >
> > Problem # 1
> >
> > The culprit is the bde/vcl bug that you have emulated. I have commented
> it
> > out. I feel that if you must do this, you should use a registry entry
to
> > control it. If I wanted really buggy things, I would use the VCL :-)
> >
> > This is to do with BindingError when the fieldtype is numeric (x.y) and
> you
> > change it to largeint. It is obviously numeirc and obviously has a
scale
> so
> > why would anyone want it to be largeint. Basically, as soon as a change
> is
> > made to a fieldtype in the database and the table is attempted to be
> opened
> > on the form - it gets an error, and then all the numeric-float fields
> want
> > to become largeints.
> >
> > I spent hours on this before finally tracking it down in the ibdataset
> code.
> >
> >
> >
> > Problem # 2 - to do with bcdfields. The fields in question used to be
> > smallint and have now been changed to numeric (9,4). On opening the
table
> > on the form (event after changing the field in the dfm and pas files to
> > tibofloatfield or tibobcdfield... when the table is opened, I get
> "Fieldtype
> > not supported" - only in the IDE. I havent figured this one out yet.
> >
> >
> > ----- Original Message -----
> > From: "Jason Wharton" <jwharton@...>
> > To: <IBObjects@yahoogroups.com>
> > Sent: Friday, 16 February 2001 16:00
> > Subject: Re: [IBO] Strange TFieldTypes
> >
> >
> > > I don't think there are enough details in the open here to be able to
> > tell.
> > >
> > > Can you tell us a little more about what is going on?
> > >
> > > Have you ensured your packages are fully refreshed?
> > >
> > > Thanks,
> > > Jason Wharton
> > > CPS - Mesa AZ
> > > http://www.ibobjects.com
> > >
> > >
> > > ----- Original Message -----
> > > From: "Rohit" <rohit@...>
> > > To: <IBObjects@yahoogroups.com>
> > > Sent: Thursday, February 15, 2001 8:28 PM
> > > Subject: [IBO] Strange TFieldTypes
> > >
> > >
> > > > After converting all TFloatFields in the 200+ forms to
> > > > TIBOFLoatFields, we now get the complaint that the field should be
> > > > largeint instead of ibofloat. The field is defined in the database
as
> > > > numeric (12,3).
> > > >
> > > > We also have the situation where the complaint for numeric (9,4) is
> > > > unsupported field type. The field selected is TIBOBCDField.
> > > >
> > > > Whats happening, does any one know ?
> > > > Regards
> > > >
> > > > Rohit
> > > >
> > >
> > >
> > >
> > >
> >
> >
> >
> >
> >
>
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>