This scenario uses the
Certadv.Schedule data set. Write a SAS program that does the following:
-
Create a macro named CourseLoc
with no parameters.
-
Use the SQL procedure to create
a series of macro variables named LOC1, LOC2, and so on, that store
the distinct values of the Location column in the Certadv.Schedule
table.
-
Use the %DO loop to execute a PROC
PRINT step once for each LOCn macro
variable that is created. The PROC PRINT step should filter data based
on the value of Location and the LOCn macro
variable. Add a title with the text 'Courses Offered in' and substitute
the value of the LOCn macro
variable.
-
Call the CourseLoc macro program.