Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Delphi and Oracle: data type problem
comp.lang.pascal.delphi.misc is more appropriate for this Q.
Delphi Integer is 32 bits. Which does include up to 10 digits, however 9,999,999,999 is not a valid delphi integer because it's greater than 2 to the 32nd power.
Delphi floating point's are accurate for up to 15 digits, hence the conversion.
I set my Primary Keys in Oracle for 20 digits. Took a while to figure out why delphi kept choking when I forced them to be integer. Don't know what will happen if the 15 digit limit is exceeded. I suppose when the ID's reach that limit, I'll be dead and burried... :-o
"Sheldon Wang" <sheldon.wang_at_cdott.com> wrote:
> Hi,
>
> I use Delphi as a front-end tool to write application that talks to an
> Oracle database. I have a problem with the Data Type conversion from Oracle
> to Delphi. In Oracle tables, I have a field with type NUMBER(10), however
> when I use Delphi's Field Editor to add the fields in Oracle tables to
> Delphi application, the NUMBER(10) field in Oracle is converted into
> TFloatField in Delphi. How does Delphi pick the field type from Oracle
> tables? I have noticed that sometimes Delphi converts NUMBER(10) to
> TFloatField, sometimes converts to TIntegerField, why?
>
> Is there a place in the Delphi's IDE where I can set something to specify
> the data type translation?
>
> I use Oracle7.3, Delphi 3 C/S suite.
>
> Thank you very much in advance.
>
> Sheldon
>
>
-- joebrown @leading.netReceived on Fri Sep 25 1998 - 00:00:00 CDT