Hi all,
plz find below mention code and give me some suggestions to rectify the problem
Problem :
By using proc report I want to generate a report I able to get the observation only, variables are not presented in the output file
kindly check with the code and try to resolve the issue
{
PROC REPORT DATA = _HED OUT= _OUT;
COLUMN( H SEQNUM COUNT);
DEFINE H / DISPLAY "HED";
DEFINE SEQNUM / DISPLAY "SEQNUM";
DEFINE COUNT / DISPLAY "COUNT";
BREAK AFTER H / SKIP;
TITLE ' CURRENT DATE SEQNUM AND COUNT OF REC';
RUN;
PROC PRINT DATA = _OUT;
RUN; }
And the results in spool
CURRENT DATE SEQNUM AND COUNT OF REC
Obs H SEQNUM COUNT _BREAK_
1 H 696 19121
2 T 0 96
and the output file it shows only observations variables are not there (H SEQNUM COUNT ) those three are not at present in the output file
****** ***************
000001 H 696 19121
000002 T 0 96
kindly give the answer to that problem and one more I
want to show in footnote next seqnum 697 how can I do by using sas code could u explain that one also
Thanks & regards
rohit Krishna
Please supply some example data (in the usual form, data step with datalines) against which we can test code, and an example for the expected output. Since we are talking list output, post the result example using the {i} button, so we can see the horizontal alignment correctly. And use the "little running man" for the example datalines step.
Please switch to Rich Text when Posting. In this mode, the {i} button is the sixth icon from the left, the "little running man" the seventh, right above your posting area.
You ABSOLUTELY(!!!) must use these buttons for code and text, as the normal posting window will invariably change the contents, and the whole vertical alignment gets scrambled. As you can see, the example lines of your input data are useless at the moment.
Only then will we be able to provide serious help.
Are your trying to use PROC REPORT to produce your report? Or PROC PRINT?
Not sure why you would want to use PROC REPORT to produce a dataset and then use PROC PRINT to print it.
Do you want a human readable report? Or another data file that you can use as input to some other mainframe program?
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.