Hi All, I want to use the Min and Max dates in the title of a report so people know what the date range is. I have used the Proc SQL to get the MIN and MAX dates. Is this the best method to use - how do I now use those dates in a title for a proc report? Data test;
Input Date $ Count;
Datalines;
42,921 4
42,922 1
42,922 1
42,922 1
42,922 1
42,922 1
42,922 1
42,922 1
42,922 1
42,926 1
42,940 1
42,940 3
42,940 1
42,940 1
42,940 1
42,941 1
42,941 1
42,941 1
42,941 1
42,941 1
42,941 1
;
Run;
Proc SQL;
Create table work.MinMaxDates AS
Select min(Date) as mindate, max(Date) as maxdate
From Test;
Quit; Proc SUmmary data=test sum;
By Date;
VAR Count;
Output out=testsum (DROP=_FREQ_ _TYPE_) SUM=;
RUN;
Title "&mindate to &Maxdate";
Proc Report data=Testsum;
Column Date Count;
Define Date / NOPRINT;
Define Count / Display f=comma8.;
Run; Any help appreciated. Cheers Dean
... View more