Data Integration

 View Only
  • 1.  Column Derivation by rule

    Posted Wed March 30, 2022 09:11 AM
    Hello guys. I am pretty new to Datastage and currently have a tax to create a column that looks at the number of calendar days (120 days YTD) for a particular column and returns a corresponding year. Anyone done something similar or have a suggestion on how to do this?

    ------------------------------
    Idowu Yusuf
    ------------------------------

    #DataIntegration


  • 2.  RE: Column Derivation by rule

    IBM Champion
    Posted Thu March 31, 2022 03:48 AM
    Hello Yusuf,

    can you please in an example (what is your Inputdata, what is the result that you want to have) specify what you want to achive? In the transformer in the expression editor you have several functions in the date group, like YearFromDate, YearFromDate, DaysInYear, DateFromDaysSince, DateOffsetByComponents to name just a view.

    KR Ralf

    ------------------------------
    Ralf Martin
    Principal Consultant
    Infologistix GmbH
    Bregenz
    ------------------------------



  • 3.  RE: Column Derivation by rule

    Posted Fri April 01, 2022 09:29 AM
    Thanks for your reply Ralf. The business process actually has people sending in some documents to our establishment. We are trying to create a stop-gap measure that looks at the date the person sent the documents to us and checks if it's within 120 days from Jan 1 of that year, then assigns the year to a different column (Year of Document).

    ------------------------------
    Idowu Yusuf
    ------------------------------



  • 4.  RE: Column Derivation by rule

    IBM Champion
    Posted Fri April 01, 2022 10:23 AM
    Hello Yusuf,

    then you should use YeardayFromDate

    Returns the day number in the year from the given date.

    https://www.ibm.com/docs/en/iis/11.7?topic=functions-date-time

    KR Ralf

    ------------------------------
    Ralf Martin
    Principal Consultant
    Infologistix GmbH
    Bregenz
    ------------------------------