Six Stars

How do I get user input from the keyboard in talend

Hi guys,

 

I would insert an input date from keyboard, store in context var the value and 

pass that var in mysql query like that:

context.var prompt like string

tjava component -> TalendDate.parseDate("yyyy-MM-dd",context.var)

tmysql component -> select * from table where date(columns) > "'+context.var+"'

 

thnx at all

 

1 ACCEPTED SOLUTION

Accepted Solutions
Nine Stars

Re: How do I get user input from the keyboard in talend

Hi, 

 

While creating context variable please select default box, then it will prompt for value when you run job.

 

ContextPrompt.PNG

ContextPrompt1.PNG

 

Regards,

 

Veeru Boppudi
3 REPLIES
Nine Stars

Re: How do I get user input from the keyboard in talend

Hi, 

 

While creating context variable please select default box, then it will prompt for value when you run job.

 

ContextPrompt.PNG

ContextPrompt1.PNG

 

Regards,

 

Veeru Boppudi
Six Stars

Re: How do I get user input from the keyboard in talend

Hi Veeranjaneyulu Boppudi,

 

thnx a lot for your description.

Very accurate!!

I'm do it and works well!

 

regards,

Davide

Six Stars

Re: How do I get user input from the keyboard in talend

Hi Veeranjaneyulu Boppudi,

 

just the last question:

I would export the job to run file .bat. But, I need insert the input (like message box) to make a query.

There's any solution to do it?

 

thnx

Dav