Forum Discussion

tech607's avatar
tech607
Occasional Contributor
12 years ago

datetime() function in Property Transfer

Hi All,

I am using xpath function xs:dateTime() in the property transfer.
Input value to the function is 2006-05-04T18:13:51-06:00 and the function returns 'Fri May 05 02:13:51 CEST 2006'
But I want the dateTime in 'YYYY-MM-DDThh:mm:ssTZD' format instead of 'Fri May 05 02:13:51 CEST 2006'.
Is there any way convert 'Fri May 05 02:13:51 CEST 2006' to 'YYYY-MM-DDThh:mm:ssTZD' format?

Thanks in advance

1 Reply

  • Aaronliu's avatar
    Aaronliu
    Frequent Contributor
    Not sure if XPath expression support the format of date, but you would get more information from W3C.
    if possible, you would use scripts to format the pattern:

    SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss")