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!

Calling Talend Open Studio Users

The first 100 community members completing the Open Studio survey win a $10 gift voucher.

Start the survey

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog

How Media Organizations Achieved Success with Data Integration

Learn how media organizations have achieved success with Data Integration

Read

APIs for Dummies

View this on-demand webinar about APIs....

Watch Now