Instead, we are starting with the MAIN procedure. The main process for this report is to set the break for page headings, select those subscribers who are not in the state of Oregon, sort them by the subscriber code, then for each one print out the name followed by all of their subscriptions. Notice that it is not necessary to set a break for the subscriber. Since we are reading the subscriber file, for each subscriber selected we can print the name and then print the subscriptions. Previously, we have mentioned selection .
Selection is the process of marking records in a file for later processing.
We want to select records that have a state other than Oregon. For each subscription we want to print the magazine code, the date the subscription was started, and the number of issues left. There is one big difference - with look ups, we were using the FIND statement that only returns a single record. As we have done it, all we would need to do is add the necessary declarations and add a FIND statement to do the magazine look up. Standard report headings are to be used, detail layout is left up to you.