Chapter Contents

Previous

Next
SAS SQL Query Window User's Guide

Creating Summary Reports

You can use the SQL QUERY Window in conjunction with the REPORT Procedure to create a summary report with totals.


Using a Saved Report Definition

For this example you are modifying the report that you created in the previous example to display the total salaries for each division. In the SQL QUERY COLUMNS window, select

Tools
[arrow]
Run Query
[arrow]
Design a Report
[arrow]
Name a predefined Report...
When the dialog displays, select SAMPLE from the list of libraries displayed. The libraries and catalogs that are listed in your display may differ from the ones in the example.

[IMAGE]

Select SQL from the list of catalogs. Select the SALARY report definition.

[IMAGE]

Click OK.

[IMAGE]


Deleting a Heading

You will not need to display education level for this report. In the REPORT window, select the EDUCATION LEVEL heading. Select

Edit
[arrow]
Delete

to delete the EDUCATION LEVEL heading from the report. You are not deleting EDUCATION LEVEL from the query.


Summarizing Information

Select the DIVISION heading. Select

Edit
[arrow]
Summarize information
[arrow]
After Item

to display the BREAK window. Select Double overline summary to print a double line over the summary total. Select Skip line after break. Select Summarize analysis columns.

[IMAGE]

Select OK to return to the REPORT window and display the total salaries for each division.

[IMAGE]

Select

File
[arrow]
Close

Select OK in the pop-up dialog to close the REPORT window and to return to the SQL QUERY TABLES window.

Select

Tools
[arrow]
Reset

to reset the query and return to the SQL QUERY COLUMNS window.


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.