Focal Point
[CLOSED] Read Excel File as a Source Stored on a Shared Drive

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

April 11, 2017, 02:38 PM
Doug
[CLOSED] Read Excel File as a Source Stored on a Shared Drive
What's the best way / best practice to Read Excel File as a Source, in 8.2, which is Stored on a Shared Drive? The Excel file is a simple one tab, several columns, the format will not change.

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




   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
April 11, 2017, 02:47 PM
BabakNYC
Try Excel (via direct retrieval) in the Adapter list on the reporting server. Unless of course you can upload into a real database.


WebFOCUS 8206, Unix, Windows
April 11, 2017, 05:11 PM
Doug
This can't reside on the WebFOCUS Servers. It resides in a folder on a Windows Shared Drive.
April 12, 2017, 05:27 AM
Hank W.
The WebFOCUS server needs to be able to access that file, so it needs to be in the path... are you on unix or windows for the WF? It needs to be a 'folder'you can navigate to... mounted directory or symlink or such.


Cheers,
H.

WebFOCUS 8.1.05M
Oracle 11g - DB2
RedHat
April 12, 2017, 06:26 AM
Wep5622
In addition to that, in our experience Excel 2007+ files aren't great with parallel access to their contents.

WebFOCUS has to unzip the file to read it, but as far as I understand, it doesn't leave it unzipped and ends up doing so over and over. This can result in it overwriting a previously unzipped version that's still in use by a parallel running TABLE request on the same file, resulting in errors.

You might want to HOLD it to a FOCUS file, or better yet, a table in a proper RDBMS. Both performance and concurrent access will be a lot better.


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 :
April 12, 2017, 07:17 AM
Hank W.
How often does that excel file change?

What I'd suggest to do, instead of accessing the excel directly, "cacheing" it along the lines what colleague Wep5622 above is suggesting. What you want to do is make a batch job that reads the excel into a FOCUS table you hold on the server disk. Or if it is updated randomly, make a "refresh" report/schedule the user can invoke after saving (unless you have a sniffer and trigger there in the share)

That way, the "use" of the excel is 1:1 by the batch job only so the conflicts above get mitigated, and you can then run reports off the FOCUS table as you please.

The question with using cacheing is "how often does the data change" and "how often does it get accessed". Say you have a dashboard with 10 dropdowns each running a dynamic report joining a couple tables. Now running a SQL query as a batch once at night vs. 1000 users 9am running the same dashboard refresh does magic to load and response times.


Cheers,
H.

WebFOCUS 8.1.05M
Oracle 11g - DB2
RedHat
April 12, 2017, 10:45 AM
Doug
Thanks Guys,

As far as the following quote goes, I need to start by getting WebFOCUS to read the file in the first place. Accessing it on the share drive seems to be the issue.

We're running WebFOCUS on Unix and my file is on a Windows share drive.
quote:
make a batch job that reads the excel into a FOCUS table you hold on the server disk.





   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
April 12, 2017, 10:52 AM
BabakNYC
Microsoft has an ODBC connection on Unix. I haven't tried this myself but that might be the approach for what you're trying to do.

Alternatively, it might be a lot easier for you to use a CSV file instead of Excel if that's an option.


WebFOCUS 8206, Unix, Windows
April 12, 2017, 11:43 AM
Hank W.
Ok, is it actually a shared drive on a physical box, or is it a SAN drive (you could access otherwise)

So, then, you need to mount the share... something like:

mount -t cifs -o username=<share user>,password=<share password>,domain=<domain> //<ip address>/<share name> /mnt  


Depends on what you have available on your boxes, google-fu the specific versions, theres stuff to do to keep the mounts after reboot or if you need different authentication or stuff.


Cheers,
H.

WebFOCUS 8.1.05M
Oracle 11g - DB2
RedHat
April 13, 2017, 08:31 AM
Doug
Thanks All,
I'll get with my Admins about this and let post my final results.
April 17, 2017, 10:16 PM
Tomsweb
test 123


Tomsweb
WebFOCUS 8.1.05M, 8.2.x
APP Studio, Developer Studio, InfoAssist, Dashboards, charts & reports
Apache Tomcat/8.0.36