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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Dynamic File name generation based upon value

Hi Guys

I am trying to change my file name based upon column value in my query, can you please help

 

Labels (1)
11 Replies
Anonymous
Not applicable
Author

Hi,

 

     You are having 17 records in your output. So I assume you want to load the data to 17 files.

 

For that, use the below flow.

0683p000009M4Oy.png

0683p000009M4P8.png

 

0683p000009M4Hj.png

 

But if you want to load all 17 records to a single file name, its very easy. Load the file name to a context variable in one of the early steps. Then in the file name column, use context variable.

 

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

Anonymous
Not applicable
Author

i want only one file but name change based upon col value, below are the shots ...i am getting error in trow generator

 

thanks for help


flow.PNG
generator.PNG
tmap.PNG
Anonymous
Not applicable
Author

Hi,

 

     You are telling that it will be one file for 17 records. In that case, the assumption is that column used to create file name will be static for all 17 records. Based on this assumption, you can create a simpler data flow.

0683p000009M4PI.png

 

This flow should be able to cater your demand.

 

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

Anonymous
Not applicable
Author

error on filename


12.PNG
Anonymous
Not applicable
Author

Hi,

 

    Apologies as I was overexcited and made a mistake. You will have to make minor change as shown below (by using buffer components in between).

0683p000009M4PN.png

0683p000009M4PS.png

 

0683p000009M4PX.pngnewly created file

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

Anonymous
Not applicable
Author

tgenerator will not work as this will not create correct number of rows...do you know ho to do it with tset global var


@nthampi wrote:

Hi,

 

    Apologies as I was overexcited and made a mistake. You will have to make minor change as shown below (by using buffer components in between).

0683p000009M4PN.png

0683p000009M4PS.png

 

0683p000009M4PX.pngnewly created file

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂


 

Anonymous
Not applicable
Author

Hi,

 

   Could you please share whether your use case is simple as shown in my above post or whether the file name will change for each record?

 

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

Anonymous
Not applicable
Author

file name will only change once with the month attached name

Anonymous
Not applicable
Author

Ok. In that case, the above method shown in my earlier post should work for you.

 

Warm Regards,
Nikhil Thampi

Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂