IBM Sterling Transformation Extender

Sterling Transformation Extender

Come for answers, stay for best practices. All we're missing is you.


#Sterling
#Supplychain
 View Only
  • 1.  Reading a hex data value

    Posted 02/02/10 07:50 AM

    Originally posted by: WTX_newbie


    I have created a type from a cobol copy book,
    There is a cobol field
    15 FM105-INVEST-DAY PIC S9(03).
    Corresponding item in type tree is created with item subclass as NUMBER, INTERPRET as CHARACTER,presentation as zoned...With min size as 0 and max as 3. I am trying to read data: 00{
    But when i run the map it says one pr more input are invalid. With the error below:

    Level 4: Offset 190, len 21589, comp 33 of 56, #1, DI 0000004B:)
    Data at offset 190 ('00{ 10...') failed item presentation test for TYPE
    X'004F' (FM105_INVEST_DAY Field CopyBook).

    Should i be changing INTERPRET from CHARACTER to BINARY? I have many fields that has this problem. Can anyone suggest the best possible way to resolve this error? Thanks in advance
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender


  • 2.  Re: Reading a hex data value

    Posted 02/02/10 04:46 PM

    Originally posted by: repanzer


    I've never imported anything into WTX without altering the type tree somewhat, but usually it's good on the "COMP-1, COMP-3" definitions, so no, I don't think you need to change that field, but;

    Level 4: Offset 190, len 21589, comp 33 of 56, #1, DI 0000004B:)

    Length 21589. I'm assuming the FM105_INVEST_DAY isn't a 20K byte field. The map just kept reading and didn't know where the field ended.
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 3.  Re: Reading a hex data value

    Posted 02/04/10 07:41 AM

    Originally posted by: WTX_newbie


    thanks for the reply.. I have a record structure
    18020100270000800 1 05........
    18020100270000800 1 10......
    18020100270000800 1 15....
    18020100270000800 1 20........
    18020100270000800 1 30........
    18020100270000800 1 31.......
    18020100270000800 1 40
    18020100270000800 1 41
    18020100270000800 1 46
    18020100270000800 1 50
    18020100270000800 1 60
    18020100270000800 1 60
    18020100270000800 1 65
    18020100270000800 1 70
    18020100270000800 1 80
    18020100270000800 1 90........
    18020100270000800 1 A5....
    ......
    18020100270000800 1 X0....
    In a TYPE TREE, I have a partitioned group that holds records 05-90 and A5-X0
    While reading the input file, the data values are going to a different records, like record 20 values are getting into A5 record. What changes i should make in the type tree so that the data is sent to the respective
    records.
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 4.  Re: Reading a hex data value

    Posted 02/04/10 09:43 AM

    Originally posted by: repanzer


    First; did you happen to figure out the field error from your first post? I just happen to be working an imported copybook for the first time in years and I'm getting stuck on the first COMP-3 field. It's reading the correct number of bytes, but throwing the error.
    (Level 4: Offset 282, len 12, comp 10 of 11, #1, DI 00000001:)
    Data at offset 282 (' ') was found to be of TYPE
    X'0032' (FIXED_FILLER Field CopyBook).

    (Level 4: Offset 294, len 3, comp 11 of 11, #1, DI 00000001:)
    Data at offset 294 ('á...') failed item presentation test for TYPE
    X'0033' (VAR_DATA_LEN_QY Field CopyBook).

    (Level 4: Offset 294, len 3, comp 11 of 11, #1, DI 00000001:)
    Data at offset 294 ('á') is INVALID data of TYPE
    X'0033' (VAR_DATA_LEN_QY Field CopyBook).

    As for you question; I'm confused as to what your map is doing. I can only assume at this point that you described the input of your map (records 05-90 and A5-X0), but are you outputting to the same type tree? When you say record type X values are getting into record type Y's fields, it sounds like you're mapping to and from the same format.

    If you have a partition on your input, you need a functional group for EACH RECORD in that partition. What type trees are you mapping to and from? Which one is partitioned?
    #IBM-Websphere-Transformation-Extender
    #DataExchange
    #IBMSterlingTransformationExtender


  • 5.  Re: Reading a hex data value

    Posted 02/04/10 10:12 AM

    Originally posted by: repanzer


    I knew I needed to use the "UNPACK" function to see the ASCII display of the COMP-3 field. The only varible you can pass to the function is a TEXT field.

    On the mainframe, I can see my 3 packed byte in hex as; 02 45 OC

    When I FTPed the file down to my desktop, the bytes were; 02 E1 OC

    I was trying to read in the 02 E1 OC and got data invalid.

    I changed the E1 to hex 45 (ascii captial E), ran the map again and it validated correctly to the pack binary value.

    In order to see or use the ascii equivient, I had to change the input to text, then use the "unpack" function, which returned; 2045.
    #DataExchange
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender


  • 6.  Re: Reading a hex data value

    Posted 02/05/10 01:56 AM
      |   view attached

    Originally posted by: WTX_newbie


    I changed item subclass as number and presentation as zoned , and it worked ... Also if you want to change these properties for all the comp fields then you need to go to the category that holds all the comp fields and propagate. I think you might be knowing this already :) I have just started working on WTX. I appreciate your help.

    For the second question. Yes , I am using the same type tree for the output also. I am just trying to validate my type tree against the input file. I am attaching my input file, please let me know how to proceed further.Thanks!
    #DataExchange
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender


  • 7.  Re: Reading a hex data value

    Posted 02/05/10 09:05 AM
      |   view attached

    Originally posted by: WTX_newbie


    here is the type tree
    #DataExchange
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender

    Attachment(s)

    zip
    attachment_14432783_map.zip   803 KB 1 version


  • 8.  Re: Reading a hex data value

    Posted 02/05/10 09:42 AM

    Originally posted by: repanzer


    "I changed item subclass as number and presentation as zoned , and it worked ... "

    In your first post, you said it was "number, character, zoned". I'm not sure what you changed.

    As for the mapping;

    You're going to need a functional map for every record type.

    =f_maprec1(Rec1:input)
    =f_maprec2(rec2:input)
    Etc.

    Also, you don’t need to build an output on a validation map, not anymore at least.
    #IBM-Websphere-Transformation-Extender
    #DataExchange
    #IBMSterlingTransformationExtender


  • 9.  Re: Reading a hex data value

    Posted 02/11/10 04:31 AM
      |   view attached

    Originally posted by: WTX_newbie


    Hi,
    I had made one more change, changed data language as Native, earlier it was EBCDIC and comp values were read properly.
    I am still facing problem reading the records in my input type tree.
    78020100270000800 1 05 ... <some data>
    78020100270000800 1 10 ... <some data>
    78020100270000800 1 15 ... <some data>
    78020100270000800 1 20 ... <some data>
    78020100270000800 1 30 ... <some data>
    78020100270000800 1 31 ... <some data>
    78020100270000800 1 40 ... <some data>
    78020100270000800 1 41 ... <some data>
    78020100270000800 1 46 ... <some data>
    78020100270000800 1 50 ... <some data>
    78020100270000800 1 60 ... <some data>
    78020100270000800 1 60 ... <some data>
    78020100270000800 1 65 ... <some data>
    78020100270000800 1 70 ... <some data>
    78020100270000800 1 80 ... <some data>
    78020100270000800 1 90 ... <some data>
    9 9D ... <some data>

    The record should be identified by 2bytes at column 22nd and 23rd. Like 20,30,31,40,41,46,50,60,70,80,90,9D
    I have added an identifier to check for 20,30... values . Also added a component rule to check for these values. But its not working out.
    I tried by having only one record in the input file .
    78020100270000800 1 46 ... <some data>
    The record is being read in the first record always. Type tree is not able to distinguish the records. Can you please suggest a way to make type tree identify these records.
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender

    Attachment(s)



  • 10.  Re: Reading a hex data value

    Posted 02/11/10 09:02 AM

    Originally posted by: repanzer


    The trace file will tell you everything the map is doing. The map is going to read a record then try to identify it as the first record in the partition, if it fail validation for that record, it tries the next record in the partition. Run the map with the trace file on and see exactly what the map is validating for each field. It will tell you why record A is failing validation for Record A, i.e.;
    (Level 2: Offset 2749, len 0, comp 1 of 1, #1, DI 00000236:)
    Data at offset 2749 ('òððù`ðø`òò@@@@ðð...') failed COMPONENT RULE test
    for component number 1, TYPE X'0006' (AC_SUM_INFO_300 A_APartitionRecords Group CopyBook).

    go through each field that returns "invalid" or failed, and fix it, until each field in record A "was found to be of TYPE record A".
    #IBMSterlingTransformationExtender
    #DataExchange
    #IBM-Websphere-Transformation-Extender