Hi,
Can someone show me how can I create a calculated field at runtime with a TOracleDataSet?
The sql is constructed also at runtime, so I *have to create the calc field at runtime, too.
I tried the following code:
f:=TIntegerField.Create(ods1);
f.FieldName:='blabla';
f.FieldKind:=fkCalculated;
f.DataSet:=ods1;
f.Name := f.Dataset.Name + f.FieldName;
ods1.FieldDefs.Add(f.name, f.DataType, f.Size, f.Required);
ods1.Open;
And seen no calc field, only the real fields...
Thanks in advance (for any info),
Koadam
Can someone show me how can I create a calculated field at runtime with a TOracleDataSet?
The sql is constructed also at runtime, so I *have to create the calc field at runtime, too.
I tried the following code:
f:=TIntegerField.Create(ods1);
f.FieldName:='blabla';
f.FieldKind:=fkCalculated;
f.DataSet:=ods1;
f.Name := f.Dataset.Name + f.FieldName;
ods1.FieldDefs.Add(f.name, f.DataType, f.Size, f.Required);
ods1.Open;
And seen no calc field, only the real fields...
Thanks in advance (for any info),
Koadam