Trouble with fkInternalCalc on Delphi 2006

Tailor K

Member²
I am using DOA 4.0.7.1 on Delphi 6 and have many fields of type fkInternalCalc. At SQL they are created as just simple to_char(null), on the dataset I put specific size on them, as it are used to store temporary data while doing some processes.
I am upgrading to Delphi 2006, and on this versions, the TFields are 'live': they change it's size when the dataset is opened - go all to 1. Is this a normal behaviour, and a bug on D6, or vice-versa? I could make something like LPad(' ', 40) on the SQL, but it will generate too much 'garbage' and network traffic for nothing.
Any help is welcome.
 
I don't understand your technique used for the IntenalCalc fields.

I guess that you are using a TClientDataSet?
Then, if you make the Fields of the ClientDataSet persistent, you could just add "InternalCalc" fields. They don't belong in the SQL.
 
I use something like this, on a TOracleDataSet: select a.code, a.name, to_char(null) process from my_table a

When creating the persistent TFields, I change the TStringField for 'Process' column to size 20, fkInternalCalc - it would not participate on my database transaction, I use it on the application as an alternate temporary storage for some internal logic.

It's working nice on D6, but with the same DOA version on D2006, after Dataset.Open it dinamically 'revalidates' all fields definitions, and change the size back to 1 - but the FieldKind remains at fkInternalCalc ...
 
So... there is nothing about that? It's unknown why worked and not now, or if it never should work?
I'll have to change my SQLs, using things like lpad(' ', 30) as internalfield and force the server to generate 'garbage' to travel over remote LAN and WAN ? Remembering that Oracle NET does not have data compression ...
 
Once my support license was corrected, can we return to this question? The ClientDataSet proposal does not apply to my program. The question is the behaviour change between Delphi6 and 2006 with the same DOA version.
 
Back
Top