Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Iterate Row by Row and pass on the row value to Job

Hello,
I need to perform following job:
There is a job named Daily_ETL which populates certain MySQL tables on a daily basis, when the a date parameter is passed to it.
Now I want to make version 2 of this job which populates those tables for past dates
For that purpose, I have a table in database which lists all dates (from 2 years back to current date).
I want to read that table row by row and pass on the date value to my job which essentially has SQL queries. The date parameter shall be embedded in those queries.
I tried tMysqlInput ->tJava but all it prints is null.
I'll be greatly thankful if this gets resolved 0683p000009MACn.png
I have attached snapshots of the job so as to correct me where I'm going wrong.
thanks.
PS- I'm new to forums 0683p000009MAB6.png
Labels (3)
5 Replies
Anonymous
Not applicable
Author

try this way:
tMysqlInput--row1-->tFlowToIterate--iterate-->tJava
the column values will be put in the global map:
globalMap.get("row1.column_name");
Anonymous
Not applicable
Author

Thank you so much John. It worked!
_AnonymousUser
Specialist III
Specialist III

Hi..

As you have worked on date , do you know how to work on time type...
Talend doesnt suppot only time data type I guess...
Please need a help regarding this...
Anonymous
Not applicable
Author

Hi jai,
All the Talend date method can be found in Talend code-->routine-->TalendDate where you can find all and globalMap.

Best regards
Sabrina
0683p000009M6CM.png
Anonymous
Not applicable
Author

hi,
you cannot write a flow in a tJava component (or using using iteration like JohnGarrettMartin suggestion).
It's the reason you 've got null value.
To flow data through tJava componenet, use tJavaRow.
regards
laurent