Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Access text data on server

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Access text data on server
 Login/Join
 
Member
posted
Need help with accessing a 250 byte record text file on a server. The server is NOT in the "ibi" path. I have tried several FILEDEF scenarios but am not able to retrieve any data. The server I'm wanting to access is a Windows server.

Pointing me to the documentation that might contain this information would be just as helpful as copying code in a reply, but the code sample route is fine, too.

Thanks,
Joe Mack, CenturyLink

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


WebFOCUS 7.6.10
Windows
all output (Excel, HTML, PDF)
 
Posts: 3 | Registered: July 15, 2010Report This Post
Expert
posted Hide Post
What FILEDEF's have you tried.

Should look like this (Windows)

FILEDEF MY_FILE DISK C:\MYDATA\MYFILE.TXT

or

FILEDEF MY_FILE DISK \\MYSERVER\MYSHARE\MYDATA\MYFILE.TXT


There are also options for the FILEDEF.
LRECL = Logical Record Length
RECFM = Record Format (F = Fixed, V = Variable)

e.g.
FILEDEF MY_FILE DISK C:\MYDATA\MYFILE.TXT (LRECL 250 RECFM F


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!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Virtuoso
posted Hide Post
quote:
The server is NOT in the "ibi" path


For the WebFOCUS server to access a file (text or any other supported format) the latter has to be accessible via the operating system. If the file is not in the same "box" where the WF server is running then you need to share that location so both the OS and WebFOCUS can access it. Mapping a drive (E:, F:, etc.) to the exact location would be helpful. From there, all you need to do is MAP that location in WebFOCUS and get to the file.

For instance, this scenario:

datasrv -> Repository of data files located in D:\shared_resources and shared as windows SMB resource (let's say "shared"). Within it you have a folder called "data" with a set of data files you need access to (e.g. mydata.txt)

wfsrv -> Box where the WebFOCUS reporting runs. From this box, via Windows, you should be able to access \\datasrv\shared\data\myfile.txt or for simplicity, you could map \\dataserv\shared as F: and then the file could be accessed as F:\data\myfile.txt. This is just OS stuff, not still related to WF.

Accessing the file from WebFOCUS should be very easy as the OS can now see it.

APP MAP DATA F:\data
FILEDEF MYFILE DISK DATA/myfile.txt 
-RUN


Al you need now is to create a masterfile for MYFILE (myfile.mas) describing your text file and then issue a regular TABLE FILE MYFILE to use it.

Take a look at "Describing Data with WebFOCUS Language" for details on how to create the master file, and "Creating Reporting Applications" for details about APP MAP, FILEDEF and other user APP statements.

Sorry, I'm not able to access IBI's tech support right now so cannot provide actual document names and/or DN#.



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Member
posted Hide Post
thanks to both who replied. I tried each of your ideas without success. Then...(of course) it dawned on me...the files I was trying to read had ticks as first and last character of the PC/server filename. This is ABSOLUTELY illegal on the main frame, but totally acceptable on the PC. So, once I renamed and removed the ticks (didn't want them in the name, really) it worked with just about all methods you provided. old dog, new tricks!


WebFOCUS 7.6.10
Windows
all output (Excel, HTML, PDF)
 
Posts: 3 | Registered: July 15, 2010Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Access text data on server

Copyright © 1996-2020 Information Builders