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.  XML element by element validation -Urgent

    Posted 09/03/09 04:27 PM

    Originally posted by: SystemAdmin


    Hi All,

    I am working on an interface with Acord XML as my Input and output is a also and XML which is not Acord but a custom Cannocial XSD .

    The Acord Input which i would be getting has no reliability on the data coming in. To explain further suppose Acord element <TransactionRequestDt> is having a data type of dateTime in the XSD but it can come with a VARCHAR , Basically the data doesnt adhere to the XSD datatypes , facets and restriction.

    for e.g.
    <TransactionRequestDt>2006-hdgshs</TransactionRequestDt>
    OR
    <CustPermId> which is a mandatory field in XSD can come as NULL
    <CustPermId/>

    My Question is is there a way to do element by element validation on the input XML payload so that we can cleanup/FIX the XML element with CUSTOM STANDARD values e.g.
    <TransactionRequestDt> if bad then put CURRENTDATETIME

    i found the VALIDATE XML function can validate the whole payload but is there a way to do it element by element.

    Please let me know , any suggestion.....

    Thanks
    KSR
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender


  • 2.  Re: XML element by element validation -Urgent

    Posted 09/04/09 07:38 AM

    Originally posted by: TarunB


    There are a couple of options but nothing that is clean and easy to implement. It would be great if TX had a feature to automatically "pre-validate" each field in the manner you describe.

    For the mandatory field where you get NULL (or NONE in TX speak) : you can edit the type tree properties for None --> Required On Input. In this case I believe that NONE will be replaced by the default value you put in this type tree parameter.

    A wider ranging option is to create a pre-validation map, loosely based on the Accord XML schema that you have. You will need to edit the source XML tree so that properties are very much open, i.e. not date/time or limited length etc. The purpose of this map is to perform the data checks and replacement of erroneous data, just like you describe in your post.

    Not really a neat way of doing things but it'll work.
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 3.  Re: XML element by element validation -Urgent

    Posted 09/04/09 10:05 AM

    Originally posted by: SystemAdmin


    Thanks Tarun-B...
    I am goign to do the same thing as you mentioned to make a pre-Validation map for the job .. will post if the solution works.

    Thanks
    ksr
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender
    #DataExchange