BookmarkSubscribeRSS Feed
tparvaiz
Obsidian | Level 7

Hi,

 

I have a sas program that saves a file. when I run it, and if the file exists, it confirms before overwriting.

 

is there a way to disable this and let excel to overwrite if the file with the same name exists

 

Thanks

3 REPLIES 3
Jagadishkatam
Amethyst | Level 16

Could you please let me know the program or log info which you are using to run. This will help us to give better response.

Thanks,
Jag
Shmuel
Garnet | Level 18

Add the REPLACE option to your FILENAME statement.

Reeza
Super User

@tparvaiz wrote:

 

is there a way to disable this and let excel to overwrite if the file with the same name exists

 

Yes, the REPLACE option. Exactly where it goes depends on how you're 'saving' your file.

PS. It would really be nice if you take the time to detail your problem rather than rushing to post a question. A good question will include the code and log if applicable or screenshots of errors if it's a pop up for example. And what you've tried so far. I guarantee if you do this you'll answer half your questions before they're posted. In addition asking if 'is there a way' or 'is it possible' the answer is usually YES. You're question is 'how do I do X with Z'. This actually requires a change in thinking because all of a sudden almost everything is possible, it becomes a matter of difficulty. Some may not be at the moment, but again changing how you frame the question also changes how it sounds to you, your colleagues and supervisors. It seems small but these are the things that will differentiate a good programmer from a mediocre programmer. 

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 847 views
  • 2 likes
  • 4 in conversation