sysdate to context variable

One Star

sysdate to context variable

The simple one.
How to put sysdate in context variable in tjavarow?

Thanks.
One Star

Re: sysdate to context variable

hi,
try this : context.new1=TalendDate.getDate("CCYY-MM-DD hh:mm:ss");
One Star

Re: sysdate to context variable

works!!! .. And how to get duration from tChronometerStop into context variable???
Ok in general we place cursor over property field and pres ctrl+space to see key for globalMap, how to do this with in this case?
Thanks!
One Star

Re: sysdate to context variable

Hi,

In a tjavarow write context.time_run=((Long)globalMap.get("tChronometerStop_1_DURATION")). Add a .toString() if you would like it to be of string type.
One Star

Re: sysdate to context variable

Thanks to both of you!
Regards!