App Connect

Expand all | Collapse all

How to create DFDL message model for Fixed length file

  • 1.  How to create DFDL message model for Fixed length file

    Posted 17 days ago
    I have a fixed length file which I need to read in to the message flow. So I tried to create a message model and tried the option "Other Text or binary" on New Message Model wizard. After defining all the elements i tested with Create logical instance to see the output and found out it created a comma separated values.
    For example FirstName of length 10 characters
                         LastName of length 10 characters
                         Dept of length 10 characters 
    Logical instance output was --> Ramesh    ,Smith     ,Sales     
    I want it to be like --> Ramesh    Smith     Sales 
    Any articles or urls or suggestions to achieve this would be a great help.
    Thank you all

    ------------------------------
    Lokesh Bonthula
    ------------------------------


  • 2.  RE: How to create DFDL message model for Fixed length file

    Posted 15 days ago
    Hello,

    did you select the option "Fixed Length" on the last page of the wizard in the "Field Settings" ?
    You should have a file called "RecordFixLengthFieldFormat.xsd" that is generated by the wizard and used to configure DFDL.

    ------------------------------
    Pierre Richelle
    IBM Hybrid Cloud Integration Specialists
    IBM
    +32474681892
    ------------------------------



  • 3.  RE: How to create DFDL message model for Fixed length file

    Posted 13 days ago
    Thank you Pierre, 
    I was using the second option : "create an empty dfdl schema, I will model my model my schema using dfdl editor"  then I was not getting this option "Fixed Length"
    After your suggestion I tried the first option "Create a DFDL schema using this wizard to guide you" which gave the option to select "Fixed Lenght"

    Thank you as per suggestion I was able to create the file called "RecordFixLenghtFieldFormat.xsd"

    Is there any way if we select second option :"create an empty dfdl schema, i will model my model my schema using dfdl editor" and change some properties to get "RecordFixLenghtFieldFormat.xsd"

    ------------------------------
    Lokesh Bonthula
    ------------------------------



  • 4.  RE: How to create DFDL message model for Fixed length file

    Posted 13 days ago
    Edited by Pierre Richelle 13 days ago
    Hello,

    yes you can but the wizard fills a lot of things OOTB that you will need to do your self afterwards.
    Here you go:
    In the representation properties, select the "..." for the Data Format Reference:

    Select add a reference to another schema:
    Select the Text Data Formats:
    You will need to remove the previous data format reference (its an include).

    ------------------------------
    Pierre Richelle
    IBM Hybrid Cloud Integration Specialists
    IBM
    +32474681892
    ------------------------------



  • 5.  RE: How to create DFDL message model for Fixed length file

    Posted 11 days ago
    Thank you Pierre Richelle for the quick response. I was able to do it in both ways. You saved my day.
    Thanks again.


    ------------------------------
    Lokesh Bonthula
    ------------------------------