Start Free Trial

Alteryx Designer Desktop Discussions

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

How to update excel file name and retain all tabs in the file?

Rosh_2788
7 - Meteor

Hello, 

 

I currently run a workflow to update the "Raw Data" tab in excel and have three other tabs which are pivot tables on top of the raw data, Here is how it looks like - 


tabs in excel file - 

Pivot APivot BPivot CRaw Data (updated via Alteryx)

 

I can't create Pivots using alteryx because it needs to be dynamic for user analysis, so make sense to only work on the raw data tab and the user can refresh the pivot and make changes as desired. Currently my File name  is static - "Monthly Template", so it refreshes just the raw data tab when a new input file is received (but obviously overwrites the previous data unless someone does a save as to the template file.) 

 

I'm looking to dynamically update the file name to Monthly Oct 2021, Nov 2021, etc, and retain the pivot tabs. The issue I run into is that if I set it to dynamically update the file name, it overwrites the entire file and I just have the "Raw Data" tab. 

 

Is there a way to just overwrite the "Raw Data" tab but also dynamically update the file name by keeping the other pivot tabs as is. 

 

Regards, 

Rosh

3 REPLIES 3
ArtApa
Alteryx
Alteryx

Hi @Rosh_2788 - If you just need to change the file name without changing the content you can use Run Command tool. Attached example Searches and Replaces a string in a folder for all files.

Rosh_2788
7 - Meteor

Hi @ArtApa, apologies for the delay.

 

I'm looking to run the workflow every month and update the 'Raw Data' tab, but selecting a new input file every month. The other 3 PIVOT tabs will be static (not updated by the workflow) and will update based on the Raw Data tab. I'm then looking to rename this file to reflect the month end date in the name (which can be sourced from a column in the input file.) 

The issue I'm facing is that as soon as i replace the file name, it overwrites the entire file, i.e. my static pivot tabs disappear.  Is there a way to just overwrite the "Raw Data" tab but also dynamically update the file name by keeping the other pivot tabs as is. 

ArtApa
Alteryx
Alteryx

Hi @Rosh_2788 - Firstly, I wouldn't keep any Pivot tables in Excel as these transformations can be done in Alteryx. Secondly, if you must have Pivot tables in Excel. You can create a template then a) Copy a template with a new name using a Run Command tool b) Populate data using an Output Data tool.

Labels
Top Solution Authors