Originally posted by: ashw_r
Hi All,
I have situation where in I am creating a typetree for third party data, but the problem is it has a variable length field with no terminator. For example below is the structure of one segment(record) in flat string.
Below table depicts record properties.
Field-----------------Length------------Comments
SegmentID-------------2Bytes------------"CC" (constant value, which can be used as intiator in WTX)
SegmentLength---------2Bytes------------Indicates length of whole subsegment (including indicator: CC).
SegmentData-----------1 to 40Bytes------Variable length field without a terminator
Sample Data for this segment: CC14SAMPLEDATA
(SegmentID= CC, SegmentLen= 14, Data=SAMPLEDATA (10Bytes), total 14bytes including all segments)
Also This segment is preceeded and succeeeded by other type of segments. And even fun part is, this segment can be repeated.
In this situation, Here I cant use SIZED Component attributes on SegmentLength, because SIZED attribute applys to the succeeding componets. Here in my case segmentLength 14 byte including preceeding field SegmentID.
I need to create the type tree for this type of data organization.
Please anyone who faced similar situation or who know how to handle this situation, give me your valuable input.
Note:At this situation
No Pading Rule
No Terminator
Thanks and Regards
Ashwin
#IBM-Websphere-Transformation-Extender#IBMSterlingTransformationExtender#DataExchange