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 (January 2004, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 23 Jan 2004 13:15:57 -0500
Reply-To:     Ben Howcroft <howcroft_2@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Ben Howcroft <howcroft_2@HOTMAIL.COM>
Subject:      Summarizing in Proc Report

Hello all,

I am trying to list the content of a table using proc report. After listing the data for each day I want to sum up the last two columns, and then to repeat this for the next day. The problem is that the summary lines are empty. Thank you,

Ben

options orientation = landscape nodate pageno=1 linesize=200 pagesize=200 fmtsearch=(proclib);

ods listing close; ods rtf file="c:\test.rtf" ;

proc report data= a.big_file nowd headline headskip style(REPORT) = {just=center} style(summary)=[foreground=cx3e3d73 background=cxaeadd9 font_face=helvetica font_size=3 just=r];

column cust day unit tot_da_pos tot_rt_pos ;

define cust / group center 'Customer' style (header) = {font_face="Arial" font_size=.5 font_weight=bold}

style (column) = {font_face="Arial" font_size=.5};

define day / group center 'Date' style (header) = {font_face="Arial" font_size=.5 font_weight=bold}

style (column) = {font_face="Arial" font_size=.5};

define unit / group center 'Unit' style (header) = {font_face="Arial" font_size=.5 font_weight=bold}

style (column) = {font_face="Arial" font_size=.5};

define tot_da_pos / display right 'Position 1' style (header) = {font_face="Arial" font_size=.5 font_weight=bold}

style (column) = {font_face="Arial" font_size=.5};

define tot_rt_pos / display right 'Position 2' style (header) = {font_face="Arial" font_size=.5 font_weight=bold}

break after mktday / ol summarize suppress skip page;

compute after day;

line 'Total for Position 1 is:' tot_da_pos.sum dollar9.2 '.'; endcomp;

run; ods rtf close; ods listing; title1; footnote1;

************************************************ NOTE: Groups are not created because the usage of tot_da_pos is DISPLAY. NOTE: There were 414 observations read from the data set A.BIG_FILE. NOTE: PROCEDURE REPORT used: real time 2.47 seconds cpu time 2.36 seconds


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