Focal Point
[CLOSED] ACROSS with break every x group

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/6367046876

September 29, 2015, 03:51 PM
klongid
[CLOSED] ACROSS with break every x group
Hello all,

I'm trying to use the ACROSS function but need it to break every 5 values of the ACROSS field. How can I do this?

 
DEFINE FILE CAR
Group/A20=EDIT(CAR, '9');
END
TABLE FILE CAR
SUM
     SALES OVER
     RETAIL_COST
ACROSS Group
END


I would like the output so that each grouping of lines (SALES OVER RETAIL_COST) has only 5 groups.

This message has been edited. Last edited by: <Kathryn Henning>,


WF Production Version: 7.64
WF Test Version: 7.64
Platform: Windows
Output: HTML, EXL2K, PDF
September 29, 2015, 06:19 PM
Doug
I'm not sure what you're asking. Perhaps you could enclose a sample output, within the brackets like you used for your code, to show what it is that you desire.

Are you want only "A B D J M" and not all of them: "A B D J M P T"? If that later, then what about "P T"?
September 30, 2015, 11:32 AM
Danny-SRL
Something like this, maybe?
  
-* File klongid01.fex
DEFINE FILE CAR
GROUP/A20=EDIT(CAR, '9');
END
TABLE FILE CAR
SUM
     SALES OVER
     RETAIL_COST
BY GROUP
ON TABLE HOLD
END
DEFINE FILE HOLD
NUM/I2=IF GROUP NE LAST GROUP THEN NUM + 1 ELSE NUM;
END
TABLE FILE HOLD
SUM
     SALES OVER
     RETAIL_COST
ACROSS NUM AS '' IN-GROUPS-OF 5
ACROSS GROUP AS ''
END



Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF