Focal Point
[SOLVED] Not able to -INCLUDE a fex within baseapp for some reason:

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

August 24, 2015, 12:12 PM
CoolGuy
[SOLVED] Not able to -INCLUDE a fex within baseapp for some reason:
Hey all,

So, I've successfully included some javascript that is under baseapp by using the following reference format in another report:

SET JSURL=/approot/baseapp/pagerefresh10.js


But when I try to do similar with a -INCLUDE like so:

-INCLUDE /approot/baseapp/getdatescal.fex


I get the following XML output saying the following:

 
<ibfsrpc _jt="IBFSResponseObject" language="EN" localizeddesc="Cannot include resource specified a86a66a4_2ecd_407d_b914_eb6382d44b56//approot/baseapp/getdatescal.fex" name="runAdHocFex" returncode="1020" returndesc="Cannot include resource specified a86a66a4_2ecd_407d_b914_eb6382d44b56//approot/baseapp/getdatescal.fex" subreturncode="0" subsystem="SSYS" type="simple">


Does anyone here know why I'm having issues with this and why I can't include fexes from baseapp in the same manner it worked before elsewhere?

Any help is greatly appreciated!

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


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.
August 24, 2015, 12:20 PM
CoolGuy
I even took out the "/" in the front thinking it might be that, but it still doesn't work. Ugh...

Migrating Reporting Server stuff from 7.x to 8.x is not as streamlined as it should be... There should be a utility for Reporting Server content as well as Managed Reporting, ReportCaster, etc. content.


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.
August 24, 2015, 12:28 PM
Francis Mariani
"approot" is only for web server files.

This is the correct way in WF 8:

-INCLUDE IBFS:/EDA/EDASERVE/baseapp/common_settings.fex

Though, the old way will work as well:
-INCLUDE baseapp/common_settings.fex



Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
August 24, 2015, 12:36 PM
CoolGuy
Thanks Francis!

That seemed to work. So by web server files you (more or less) mean any file extension that is/can be web related right? Because the /approot/ reference format has worked thus far for a .js file. So, if the file type is say .htm or .css we would use the /approot/ type of reference?

Thanks for your help and patience as I learn this stuff.


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.
August 24, 2015, 01:24 PM
Francis Mariani
The file type is coincidental.

The web server serves files associated with web pages - these could be html, js, css or images.

The reporting server deals with files related to WF, fex, html, sty...

in a multi-tier environment the main folders referenced by these two servers will most likely be two physically different folders one on the web server and one on the reporting server. On the reporting server the folder is usually Dive:\ibi\apps. On the web server it could be anywhere, with a web server alias called approot referencing the folder.

In a single-tier environment, the folders could be the same physical folder, with the reporting server and web server configured appropriately (the web server still needs an alias for approot).

In either situation, your code has to reference the files correctly - using approot for web server related files and -INCLUDE app-folder-name/blah_blah.fex or -HTMLFORM app-folder-name/bling_bling.htm

All this is in layman's terms - someone smarter than me can correct my terminology...


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
August 24, 2015, 03:27 PM
CoolGuy
Thanks Francis!

Your explanation was great. It was somewhat frustrating when that wasn't understood and I was trying to use /approot/... for IBFS:/... references, etc.

Important stuff to know!


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.
August 24, 2015, 06:01 PM
Waz
If you are running from MRE, then you can also add -MRNOEDIT

e.g.

-MRNOEDIT -INCLUDE getdatescal.fex

Assumes that baseapp is in the path and aaccessible.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

August 24, 2015, 06:37 PM
CoolGuy
Waz,

Good to know! Thanks for the added insight!


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.
August 25, 2015, 04:15 AM
Wep5622
The distinction in paths is between referencing files on the file system (for -INCLUDE etc) and referencing web resources on your web-server.

For javascript, css and html files you need /approot, because your web-browser needs to locate those files on the web-server. The WebFOCUS server/client don't touch those files, that's (slightly simplified) the web-server's job.

On the other hand, fex files, focus databases, etc. are accessed by the WebFOCUS server/client, not by your web-browser, so those have to be physical paths on the file-system. Those paths be relative to the working directory of the WebFOCUS (server) application, or just somewhere in its search path (APP PATH).


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
August 25, 2015, 10:28 AM
CoolGuy
Wep5622,

Thanks for your added insights. So, despite the htm, css, js, gif, etc. files being in an app folder on the Data Servers side with the other .fex,.mas,.acx,.foc, etc. files already there, they still must be called using the /approot/... referencing instead of the IBFS:/EDA/EDASERVE/baseapp/fileName.htm way of doing it? Because when I used a reference to an image that was on the Content side like...
IBFS:/WFC/Repository/Warehouse/Hidden_Content/images/logo.gif

...it seemed to work without a hitch.

So when having to reference a web type file under the Data Servers side, it needs /approot/... but if it's a .fex, .foc, .mas, etc. it needs the IBFS:/... way of reference. Am I getting that right?

Thanks!


8.2.02M (production), 8.2.02M (test), Windows 10, all outputs.