BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi Friends,

I need the 2 reports in sepearate page of PDF. The first report is given in Fig 1 which should have only one dataset rows but the report 2 will have 2 dataset datas with two different title as given in fig 2. Please help me friends.

Figure 1
Report 1- title

a d b d - column hearder which should be bold
1 2 3 4
.
.
.
12 month data 2 3 4 - last row of dataset which should be bold.

Figure 2
Report 2
Title -1
a d b d - column hearder which should be bold
1 2 3 4
.
.
.
12 month data 2 3 4 - last row of dataset which should be bold.
Title -2
a d b d - column hearder which should be bold
1 2 3 4
.
.
.
12 month data 2 3 4 - last row of dataset which should be bold.
2 REPLIES 2
Cynthia_sas
SAS Super FREQ
Hi!
The ODS STARTPAGE= option allows you to control where page breaks are inserted into your output file. This code starts out by turning page breaking off (STARTPAGE=NO) and then inserts a page break control (STARTPAGE=NOW) between procedure 1 and procedures 2 and 3);

The style(total)= override on the Proc Print statement is making the summary line bold. Of course, that works in conjunction with the SUM statement in PROC PRINT. If your tables are produced with a different procedure, you might need to use different syntax.

Good luck!
cynthia [pre]
*** the code;
ods pdf file='c:\temp\selvi.pdf' startpage=no;

proc print data=sashelp.shoes(obs=12) noobs
style(total)={font_weight=bold};
title1 'First Report';
var region subsidiary product sales inventory;
sum sales inventory;
run;

ods pdf startpage=now;

proc print data=sashelp.shoes(obs=12) noobs
style(total)={font_weight=bold};
title1 'Report 2 and Report 3';
var region subsidiary product sales inventory;
sum sales inventory;
run;

proc print data=sashelp.shoes(obs=12) noobs
style(total)={font_weight=bold};
var region subsidiary product sales inventory;
sum sales inventory;
run;
ods pdf close;

[/pre]
deleted_user
Not applicable
Hi Friend,

Thanks. I will try and let you know.

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!

How to Concatenate Values

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.

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
  • 2 replies
  • 774 views
  • 0 likes
  • 2 in conversation