[Solved]flattening out data using an across hold file
I would like to flatten out some health information using an across hold file but I can't seem to get it to work. Whenever I try to put the information into the hold file I get the message '(FOC070) ACROSS IS IMCOMPATIBLE WITH THE REQUEST' Below is the code that I am using and an example of the output I get. I know I can create hold files for each HLTH CODE but I thought there should be an easier and more efficient way of doing this.
TABLE FILE SYVSTAI
SUM
IMMU_CODE
BY ID
ACROSS HLTH_CODE
END
MEA1 MEA2 MUM1 MUM2 MCV PPD
3456 CO CO FE
4456 CO CO RE RE
5433 CO CO CO CO CO CO
This message has been edited. Last edited by: Trudy,
WF8 Windows
August 27, 2018, 10:04 AM
Dave
hi,
yeah. And easier way is possible.
1) Make a define for each column.
DEFINE FILE SYVSTAI
MEA1_CODE = IF HTLH_CODE EQ 'MEA1' THEN IMMU_CODE ELSE '';
MEA2_CODE = IF HTLH_CODE EQ 'MEA2' THEN IMMU_CODE ELSE '';
etc.etc.
END
2) magic match!
MATCH FILE SYVSTAI
SUM IMMU_CODE AS 'MEA1'
BY ID
WHERE HLTH_CODE EQ 'MEA1'
RUN
FILE SYVSTAI
SUM IMMU_CODE AS 'MEA2'
BY ID
WHERE HLTH_CODE EQ 'MEA2'
RUN
etc.etc.
_____________________ WF: 8.0.0.9 > going 8.2.0.5
August 27, 2018, 10:18 AM
Frans
Or use format FOCUS:
TABLE FILE CAR SUM SALES BY COUNTRY ACROSS CAR ON TABLE HOLD FORMAT FOCUS END -RUN TABLE FILE HOLD PRINT * END
Just to wrap up this thread, I wondered if you could pass along your version of WebFOCUS and which HOLD FORMAT you were using when you got that FOC070.