Use Case:
Adding a Specific Number of Days to a Database Fetched Date in the Format YYYY-MM-DD
Logic Steps:
- Convert the input date (in YYYY-MM-DD format) to a date object using the date() function.
- Add the required number of days using the dayTimeDuration("P10D") function (e.g., for 100 days, use "P100D").
- Finally, convert the result back to a string using the string() function.
Solution :
string((xsd:date(/nstrgmpr:execute/ns20:request-wrapper/ns20:inputDate) + xsd:dayTimeDuration("P10D")))
No comments:
Post a Comment