1. To use this method, please place the attached class file in customClasses folder:
customClasses is under the ServerKernel folder.
>>>> Place the attached file into this folder with name as "DateUtils.class"
2. Restart the Adeptia kernel and webrunner
3. Now open the Mapper and in the bottom right menu under GlobalMethods you will see DateUtils() method.
4. Now select the Target element and double click on this method and you can now use it in the Textual Rules mode.
There are 9 arguments need to be pass in this function.
o Input Date
o Input Date Format
o Output Date Format
o Year need be added/subtracted
o Month need to be added/subtracted
o Day need to be added/subtracted
o Hour need to be added/subtracted
o Minutes need to be added/subtracted
o Seconds need to be added/subtracted
Example to decrement Date by one day:
java:DateUtils.DateAdd($TextFileSchema/Root/Record/MyDate, 'yyyy-MM-dd', 'yyyyMMdd', '0' , '0', '-1', '0', '0', '0')
Note: To add or subtract the hour. minutes or seconds the input date must have the time stamp as part of its value.