BookmarkSubscribeRSS Feed
deleted_user
Not applicable
please tell me that there is any difference, when we write keep & drop in option and procidure statement
7 REPLIES 7
Doc_Duke
Rhodochrosite | Level 12
Except for their being opposites, there is no functional difference. A decision about which to use is more about programming style than technical substance.
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
A consideration is that the DROP= is honored over the KEEP= when both parameters are coded for a specified SAS variable.

Scott Barry
SBBWorks, Inc.
deleted_user
Not applicable
keep and drop options are specified in the datastep or proc , the difference is when we write options in datastep it will be permanent to the dataset but where as in proc , it will not be permanent and stays affect fot that particular session only. Message was edited by: reena
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Of course, this presumes the PROC and whether or not there is a permanent output file generated, not just a file going to the WORK or SASUSER allocation.

Scott Barry
SBBWorks, Inc.
deleted_user
Not applicable
hi sbb,
I didn't get your answer.Could you explain it briefly.

Thanks,
regards,

bina
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
It is very much possible to affect a SAS permanent library when using the DROP= and/or KEEP= parameter, if you have WRITE authority to your SAS permanent database. This capability will be dependent on the user's session and their authority permissions. For example, consider this code:

PROC SORT DATA=PERMIN.MASTER OUT=PERMOUT.MASTER (DROP=X Y Z);
BY ....;
RUN;

If the OUT= (here PERMOUT) is a permanent library, not just for your session, the result is not going to be just for your session.

Scott Barry
SBBWorks, Inc.
deleted_user
Not applicable
Thanks to all. I got my answer.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 7 replies
  • 723 views
  • 0 likes
  • 3 in conversation