Focal Point
[SOLVED] ON ACROSS SUBTOTAL FIELD crashes the run

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

May 13, 2019, 02:08 PM
John_Edwards
[SOLVED] ON ACROSS SUBTOTAL FIELD crashes the run
I have a very simple focexec:

TABLE FILE WITH_DOCS
SUM WITH_ICN/I9C AS 'With ICN'
    WITHOUT_ICN  AS 'Without ICN'
    TOTAL AS 'Total'
ACROSS DOCS AS ''
BY WEEK_ENDING AS 'Week'
WHERE DAY_OF_WEEK EQ '6';
ON DOCS SUMMARIZE WITH_ICN
END


The ON DOCS SUMMARIZE line (second to the end) crashes the run hard. "Could not get error message" hard. If I remove the field name it runs.

Does it for sub-total, subtotal as well. I'm just looking to total one field. Any recommendations on how to proceed?

This message has been edited. Last edited by: FP Mod Chuck,



May 13, 2019, 02:33 PM
BabakNYC
What's the format of DOCS?


WebFOCUS 8206, Unix, Windows
May 13, 2019, 02:55 PM
John_Edwards
Text. A20.



May 13, 2019, 03:00 PM
BabakNYC
I tried this on CAR file and couldn't reproduce. How many instances of DOCS are there? Maybe you have a very wide report. As a test can see what happens when you switch from ACROSS to BY? Does the problem go away?

  
TABLE FILE WITH_DOCS
SUM WITH_ICN/I9C AS 'With ICN'
    WITHOUT_ICN  AS 'Without ICN'
    TOTAL AS 'Total'
BY DOCS AS ''
BY WEEK_ENDING AS 'Week'
WHERE DAY_OF_WEEK EQ '6';
ON DOCS SUMMARIZE WITH_ICN
END



WebFOCUS 8206, Unix, Windows
May 13, 2019, 03:07 PM
John_Edwards
Just two. This is a really small report. I need the grand total and I can run with ON DOCS SUMMARIZE and get a total for all three of the fields. What I really want is

ON DOCS SUMMARIZE TOTAL

. . . but I didn't want to put the word TOTAL into the mix in the forums, as it's a word used in other places. I'm getting the same crash regardless of which column I try to specify.

Can I multi-verb this critter onto the end? I think it would need to have the same ACROSS field on it and that would stop getting me a single column.



May 13, 2019, 09:22 PM
John_Edwards
Works with a BY instead of an ACROSS.



May 16, 2019, 06:51 AM
Danny-SRL
There is no ON for an ACROSS field...


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

May 16, 2019, 09:25 AM
John_Edwards
Then perhaps it's an unofficial feature? Because "ON DOCS SUMMARIZE" in the source code above works perfectly. It's when I add a fieldname at the end that the walls come down.



May 16, 2019, 11:36 AM
Tony A
OI Would be inclined to change the TOTAL fieldname as it's a reserved word.

However, the following works in 8.2.05. You will still get the columns that you do not include in the SUMMARIZE.

DEFINE FILE CAR
  TOTAL/D12 = RCOST + DCOST;
END
TABLE FILE CAR
  SUM RCOST
      DCOST
      TOTAL
ACROSS COUNTRY AS ''
BY MODEL
ON COUNTRY SUMMARIZE TOTAL
ON TABLE SET PAGE NOLEAD
ON TABLE SET STYLE *
  grid=off, $
ENDSTYLE
END
-RUN


T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10