Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Output data into multiple excel files with the file's order as it is in Alteryx workflow

HungCuong_HCM
7 - Meteor

Hi all, 

 

I have done the output data into multiple excel files in 1 folder as advised here 

https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Output-data-into-multiple-files/td-p/1...

 

However, all the excel files output are sorted in the order of the folder's rule like File name ascending or descending, which i do not want like the 1st picture. 4 excel files are will be sorted from American home to Dea chang kum. 

 

I want the order is the same as my rules in the workflow, for example the Fee column as descending in the 2nd picture, Dea chang kum excel file first and American home will be the last file. 

 

1st pic:

HungCuong_HCM_1-1608711665052.png

 

2nd pic:

HungCuong_HCM_2-1608711688612.png

 

Anyone has a solution for this?

 

Thank you in advance!

 

9 REPLIES 9
RishiK
Alteryx
Alteryx

@HungCuong_HCM are you able to attach your workflow here or a screenshot?

Are you sorting by the Fees also in your workflow?

 

 

HungCuong_HCM
7 - Meteor

Hi @RishiK ,

 

Thanks for your reply! Sorry i can not upload the workflow due to confidentiality. But yes, i did sort the fee in my workflow and i would want the output files are sorted as the order of my workflow but it keeps the sorting order of the folder. 

 

Is this information enough or what else do you need? Please share!

 

Thanks!

RishiK
Alteryx
Alteryx

@HungCuong_HCM it may be easier if you book a Virtual Session with one of us and we can help you online:

https://community.alteryx.com/t5/Virtual-Solution-Center/tkb-p/vsc

HungCuong_HCM
7 - Meteor

Hi @RishiK ,

 

Thanks for the sharing! Great chanel, i will use it the next time i got question. 

 

I think this image will be easier: After running workflow my output excel files will be like this: 

 

HungCuong_HCM_0-1608787805839.png

 

But i want these files to be sorted in the order of my Fee order as it is in the workflow: 

 

HungCuong_HCM_1-1608787839247.png

 

Thanks a lot!

Qiu
20 - Arcturus
20 - Arcturus

@HungCuong_HCM 
The output file order is controlled by your OS, not Alteryx anymore.

Would your mind to have a prefix to your output file name?

Such as 1-Dea Chang Kum Ltd.

If yes, we can do something about.

HungCuong_HCM
7 - Meteor

Hi @Qiu , 

 

Yes. I think that will do. 

 

Thanks!

Qiu
20 - Arcturus
20 - Arcturus

@HungCuong_HCM 
I went back to the post you mentiond as reference, so I think we can do the following.

 

1. Add a Record ID tool before output.

2. Formula for new path:

"C:\<Your Directory>\" +Tostring(RecordID)+'-'+ [Field value to use as file name]  + ".xlsx|||<Sheet Name>"


HungCuong_HCM
7 - Meteor

Thanks a lot for your help! @Qiu @RishiK 

Qiu
20 - Arcturus
20 - Arcturus

@HungCuong_HCM 
Glad to help and thank you also for the accept mark!

Labels