We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Server Discussions

Find answers, ask questions, and share expertise about Alteryx Server.
SOLVED

error Unable to delete Excel file while running chained apps in server

Alter_Shivi
7 - Meteor

Hi All,

 

I have 2 apps as chained apps, they are working fine in designer while it give error when saving to server.

 

my app1 reads a file1.xlsx, creates an output file2.xlsx where i have column names (headers) in the format NAME and VALUE. the app2 again reads the file1.xlsx but gives user the list box letting users to select which column they want. and finally app2 gives an output called ouput1.

 

I have saved it with all the assets of app1 and app2.

 

now when i run it in server, it is giving error at the tool id oof output from app1. The error says 

"Unable to delete Excel file (C:\ProgramData\Alteryx\Service\Staging\3988_b8df92xxxxx\file2.xlsx). Make sure the file is writable and not open for writing in another application (ToolId: 28)"

 

 

I have tried to write the files in .\, %temp%, mapped sharepoint location in local machine.

4 REPLIES 4
apathetichell
20 - Arcturus

your temp files should not be in a sharepoint drive --- they should be on server in a temp directory that alteryx uses when running your workflow. I have 0 interested in troubleshooting why sharepoint does what sharepoint does. but I would hypothesize that because sharepoint is sharepoint alteryx is able to create temp files there but not able to save them. Don't mess with something that works (using Alteyrx temp locations).

 

I'd also say it might be worth having you alteryx admin check out those directories on the server themselves to see if they can delete the files.

Alter_Shivi
7 - Meteor

Thanks for your response, but I never said temp file is in sharepoint drive, i meant i tried multiple scenarios of writing the file2 in different locations like 1) .\     2) %temp%      3)sharepoint location mapped to local machine

apathetichell
20 - Arcturus

use [Engine.WorkflowDirectory]

Alter_Shivi
7 - Meteor

okay i found an accidental solution to this.

i saved my app1 along with assets (files, app2 etc). then i opened this server workflow in designer, and in interface i again located the app2 and saved again. i dont know what happened but it works.

1. save the apps as usual

2. again locate the app2 in your local machine

3. save again

 

this time app 2 would be saved as external app. i think the issue was intermediate file is used simultaneously