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.  Partition on Date Calculation in Type Tree

    Posted 08/28/09 09:36 AM

    Originally posted by: rarw


    Hi,

    I am trying to do a split/partition in the type tree based on a date calculation as shown below. The first part of the logic works (MID), but the second part of the “OR” logic involving the date calculation does not.

    The date calculation needs to keep records which are 13 months old or less (approximated to 390 days); dates greater than 13 months from the current date get put into the second bucket. The date is in CCYYMMDD format.
    MID($,187,8)="99999999" | ((DATETONUMBER(CURRENTDATE())-DATETONUMBER(TEXTTODATE($)))<390)

    I appreciate any help you can offer.
    Thanks
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender
    #DataExchange


  • 2.  Re: Partition on Date Calculation in Type Tree

    Posted 08/28/09 02:02 PM

    Originally posted by: rarw


    Hi,

    I am answering my own post; there was an oversight on my part. The $ argument in the date function (TEXTTODATE($)) must use the MID function. The code below appears to work so far - additional parenthesis added to control the execution order.

    ( ( MID($,187,8)="99999999" ) | ( ( ( DATETONUMBER(CURRENTDATE() ) ) - ( DATETONUMBER(TEXTTODATE(MID($,187,8) ) ) ) ) < 390 ) )

    Thanks for your time.
    #IBMSterlingTransformationExtender
    #DataExchange
    #IBM-Websphere-Transformation-Extender