Focal Point
columns following an ACROSS

This topic can be found at:

October 14, 2004, 09:45 PM
<Lisa M>
columns following an ACROSS
I need to create a report which includes an ACROSS (# quotes by month, total #-using row total), but which also needs to display additional information in the same BY (total sales $, average $ per month).

Here's what I'm looking to output:


I'm ok with creating the BY and ACROSS, but can't get any other columns to be in the same BY but not in the ACROSS. I'm looking to avoid defining fields for each month (too slow) or creating HOLD files.

Any suggestions would be greatly appreciated!
October 15, 2004, 09:32 PM
David Briars
Hi Lisa,

You can code COMPUTE commands after your ACROSS phrase. This will get you columns after your BY/ACROSS matrix.

For example:

  <br /><br />TABLE FILE CAR<br />SUM    RCOST     NOPRINT<br />       CNT.RCOST NOPRINT<br />       AVE.RCOST NOPRINT<br />BY     CAR<br />SUM    RCOST     AS ''<br />BY     CAR<br />ACROSS COUNTRY   AS 'Country'<br />COMPUTE TOT_RCOST/D7 = C1;  AS 'Total Rcost'<br />COMPUTE CNT_RCOST/D7 = C2;  AS '# OF Cars'<br />COMPUTE AVG_RCOST/D7 = C3;  AS 'Avg Rcost'<br />END
Running this TABLE will give you three calculated columns to the right of the matrix.

It is kind of hard to do a meaningful ACROSS report against the CAR database, but you should get the idea from this example.