Focal Point
OLAP bug when using alternate files

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

April 04, 2008, 12:27 AM
Anatess
OLAP bug when using alternate files
Hi All -

I found a little quirky thing on OLAP and USE files. I didn't find any doc on this in FP nor the manual, so I'm not sure if this is an ID-10-T error on my part. Can somebody verify this for me?

When running an OLAP report with a USE command to specify an alternate file, the OLAP opens up with the data from the alternate file but when you drill-down in OLAP or change the view or even just click reset, the resulting data comes up using the original file (file matching the master file name). What am I doing wrong?

I'm putting my code below. I created CAR2.FOC and zero'd out the DCOST and RCOST of the Jaguar car just so I can tell there's a difference between CAR.FOC and CAR2.FOC. When the OLAP Report first comes up, sure enough Jaguar Costs are zero'd out. But you click on something and Jaguar gets the costs from CAR.FOC.
USE ibisamp/CAR2.FOC AS CAR
END
-OLAP ON
OLAP DIMENSIONS
-* DIMENSIONS FILE car
COUNTRY: COUNTRY, CAR, MODEL;
END
TABLE FILE CAR
PRINT
DEALER_COST
RETAIL_COST
BY
COUNTRY
ON TABLE SET PAGE-NUM OFF
ON TABLE NOTOTAL
ON TABLE SET ONLINE-FMT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET AUTODRILL ON
ON TABLE SET OLAPPANE TABBED
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='Letter',
LEFTMARGIN=0.250000,
RIGHTMARGIN=0.250000,
TOPMARGIN=0.250000,
BOTTOMMARGIN=0.250000,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='TIMES NEW ROMAN',
SIZE=10,
COLOR='BLACK',
BACKCOLOR='NONE',
STYLE=NORMAL,
$
ENDSTYLE
END



I'm on 7.1.3


WF 8.1.05 Windows
April 04, 2008, 04:54 AM
GamP
Remember, OLAP is implemented through the applet method.
That means that everything in the request is transferred to a java applet, and whatever you do with the olap report stays within the applet. Anything that you specify after the -OLAP ON line is transferred to the applet.
Your use statement is issued BEFORE the -OLAP ON, so every request is being run against the car file, not the use car2 file, except the first request, because the initial request is not run from the applet.
Specify the USE statementAFTER the -OLAP ON, and you'll be ok.

Hope this helps ...


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
April 04, 2008, 12:25 PM
Anatess
GamP... you are absolutely correct. Thanks! I love this answer. It gives me a big a-ha moment and not just a "do this" kind of thing... I mean, before you even said the USE statement was before the -OLAP ON line, the explanation before that already made me say, yeah that's right, I should move USE... so, not only did I get a fish, I got the fishing pole as well!


WF 8.1.05 Windows