LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (February 2000, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 1 Feb 2000 10:21:43 +0100
Reply-To:     detecsm_hellriegelg@WESTLB.DE
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Gehard Hellriegel <detecsm_hellriegelg@WESTLB.DE>
Subject:      Re: is there such a thing as "if dataset not empty then..."?
Content-Type: text/plain; charset=us-ascii

Maybe that will not run ok, because the data-step will not run, or it is not of type DATA, or it has deleted obs...

%let maybe=*; data _null_; set somedata; call symput("maybe"," "); if _n_=1 then stop; run;

"Berryhill, Tim" <TWB2@PGE.COM> on 31.01.2000 23:38:52

Bitte antworten an "Berryhill, Tim" <TWB2@PGE.COM>

An: SAS-L@LISTSERV.UGA.EDU Kopie: (Blindkopie: DeTeCSM HellriegelG/D/ExternalStaff/WLB) Thema: Re: is there such a thing as "if dataset not empty then..."?

DATA _NULL_; IF NOBS GT 0 THEN CALL SYMPUT('MAYBE',' '); ELSE CALL SYMPUT('MAYBE','*'; STOP; SET SOMEDATA NOBS=NOBS; RUN;

&maybe PROC PRINT DATA=SOMEDATA;RUN;

> ---------- > From: Andrea Wainwright[SMTP:andrea.wainwright@CAPITALONE.COM] > Reply To: andrea.wainwright@CAPITALONE.COM > Sent: Monday, January 31, 2000 2:10 PM > To: SAS-L@LISTSERV.UGA.EDU > Subject: is there such a thing as "if dataset not empty then..."? > > I would like to check to see if a dataset contains any obs and run a > proc print if it does, otherwise I just want to skip it. > > What are some of the possible ways of accomplishing this? > > TIA > > Andrea Wainwright >

Mit freundlichen Gruessen

DeTeCSM, Gerhard Hellriegel

WestLB Abteilung: 001-80622 Aderstr. 22 D - 40217 Duesseldorf Tel.: +49211 826 6173 Fax: +49211 826 5393


Back to: Top of message | Previous page | Main SAS-L page