Focal Point
[SOLVED] Remove restriction for a subfoot/subhead condition to be a 'by' field

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

October 31, 2008, 09:18 AM
Martin_fmi
[SOLVED] Remove restriction for a subfoot/subhead condition to be a 'by' field
Hello everybody - I was wondering if there is a way to remove the demand for a 'by field' when using multiple subfoots/subheads.
Thanks in advance.

This message has been edited. Last edited by: Martin_fmi,


WF 7.6.5 / OS: XP / FOCUS
October 31, 2008, 09:47 AM
<JG>
You must use a BY when using subfoot/subhead but you can always use NOPRINT if you do not want to see it.
October 31, 2008, 10:03 AM
Martin_fmi
Thanks but we are porting from a different language to WebFocus and the order is of significant meaning ( not crucial but it would be better ). So it is seems that 'by' fields cannot be omitted in no way.


WF 7.6.5 / OS: XP / FOCUS
October 31, 2008, 10:18 AM
Prarie
You can do an ON TABLE SUBFOOT OR SUBHEAD


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
As Prarie says you can use ON TABLE which is an implicit BY REPORT.

Are you wanting to insert 'freeform text' or data.

If you have a known structure then you can artificially create BY sequencers
for instance based on a row count.

 
DEFINE FILE CAR
COUNTER/I5 WITH MODEL=LAST COUNTER +1;
BREAK/I5= DECODE COUNTER(1 1 2 1 3 1 4 2 5 3 6 3 7 3 8 4 ELSE 99);
END
TABLE FILE CAR
PRINT MODEL DCOST
BY BREAK NOPRINT
ON BREAK SUBFOOT
"This is comment <BREAK"
END

Thanks both Smiler

Here is a solution to my problem. Sorry for the dummy topic - it just did't come up into my mind earlier:
 
DEFINE FILE CAR
IND/I3 WITH MODEL = IND+1;
END

TABLE FILE CAR

PRINT MODEL COUNTRY
BY IND NOPRINT
ON IND SUBFOOT
"SUBFOOT"
WHEN COUNTRY NE LAST COUNTRY
-* or a different condition
END
-RUN
-EXIT 



WF 7.6.5 / OS: XP / FOCUS