ValueById(Id: String): Variant;
Id is a field ID.
The ValueById property determines value of a flat record field, the identifier of which is passed by the Id parameter.
Sub UserSub(Input: IEtlPlainRecordSets; Output: IEtlPlainRecordSets);
Var
RecordSetIn, RecordSetOut: IEtlPlainRecordSet;
RecordIn, RecordOut: IEtlPlainRecord;
i: Integer;
Begin
RecordSetIn:=Input.Item(0);
RecordSetOut:=Output.Item(0);
For i := 0 To RecordSetIn.Count - 1 Do
RecordSetOut.Add;
RecordIn:=RecordSetIn.Item(i);
RecordOut:=RecordSetOut.Item(i);
RecordOut.ValueById("FIELD00"):=RecordIn.ValueById("FIELD02");
End For;
End Sub UserSub;
This example is a macro used to transform data in ETL task. After executing the ETL task, consumer field with the Field00 identifier is put in correspondence with source field with the Field02 identifier.
See also: