Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Dynamic table creation

Hii All,

I am new t talend i have a requirement where i have input file like

Date                       Hall_Number      Booked_by

01-10 Jan 2018       hall 2                  Rajesh

05-20 Feb                hall 5                  Naresh

 

i want to change this format into 

Date                      Hall_Number         Booked_By

01-Jan-2018            hall 2                    Rajesh

02-Jan-2018            hall 2                    Rajesh

.

.

05-Jan-2018            hall 2                    Rajesh

05-Feb-2018           hall 5                     Naresh

06_Feb-2018          Hall 5                    Naresh

.

.

.

.

.

please help me how to do this...

 

Thanks & Regards

Mastan Shaik

 

Labels (2)
1 Solution

Accepted Solutions
vboppudi
Partner - Creator III
Partner - Creator III

Hi,

 

Please find the details below. There might be easy way to achieve this using java code for loop. I am not good at Java so tried to implement this  without using java looping. For this you need to first identify start date and end date for input date. Used tMap1 to derive these values and difference between these two dates. created context variable to assign these difference in dates and used that context variable in Oracle to get number of records.

 

0683p000009Lsvv.png0683p000009LtR3.png0683p000009LtSL.png0683p000009LtZ6.png0683p000009LtSD.png

 

Regards,

View solution in original post

4 Replies
vboppudi
Partner - Creator III
Partner - Creator III

Hi Mastan,

 

So you want to generate number of records based on input date range?

 

Regards,

Anonymous
Not applicable
Author

Hi,

Thanks for respond,

Yes, I want to generate number of records based on input date range. which i send already..please send me sample job design.

 

 

Thanks & Regards

Mastan SHaik

vboppudi
Partner - Creator III
Partner - Creator III

Hi,

 

Please find the details below. There might be easy way to achieve this using java code for loop. I am not good at Java so tried to implement this  without using java looping. For this you need to first identify start date and end date for input date. Used tMap1 to derive these values and difference between these two dates. created context variable to assign these difference in dates and used that context variable in Oracle to get number of records.

 

0683p000009Lsvv.png0683p000009LtR3.png0683p000009LtSL.png0683p000009LtZ6.png0683p000009LtSD.png

 

Regards,

Anonymous
Not applicable
Author

thankyou fro shatrig the screen shots 

.But i still getting the run time error

ALL_ROWS all_tables' doesn't exist.

what is the purpose of select statement in the torcle component

"select rownum-1 as rno from ALL_TABLES where ROWNUM<="+context.numDays

 

please explain