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] on data source

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] on data source
 Login/Join
 
Member
posted
Hi all,

I have created a new master file. I want to add some data (.foc file) into it. Is power painter an only option?
If not then how do i do that? If someone explain with an example then it would be fine.

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


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
 
Posts: 23 | Registered: July 02, 2008Report This Post
Virtuoso
posted Hide Post
where does your data come from?


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Member
posted Hide Post
Hi danny,

It is just a dummy file with only one field like the one given in the post on McGyver's technique.

When i run the file it says No .Foc file found. so my question is, how do populate that file to make the procedure run?


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
 
Posts: 23 | Registered: July 02, 2008Report This Post
Expert
posted Hide Post
Look up the MODIFY command and use FIXFORM and the DATA statement to populate your file.

However, if you are using McGyver, you can also use a flat file.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Virtuoso
posted Hide Post
Vasantha

As Ginny says: read up on the MODIFY command.

You say that your focus file has one field. Something like this:
  
FILENAME=NUM,SUFFIX=FOC
 DATASET='C:\ibi\apps\baseapp\NUM.FOC'
SEGNAME=ORIGIN,SEGTYPE=S1
 FIELDNAME=NUM,NUM,I3,$

Suppose you want to load numbers from 1 to 100. You use the MODIFY command:
  
MODIFY FILE NUM
FREEFORM NUM
MATCH NUM
ON NOMATCH INCLUDE
ON MATCH REJECT
DATA
-REPEAT #VASA FOR &I FROM 1 TO 100;
NUM=&I ,$
-#VASA
END

This should do the trick.


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Member
posted Hide Post
Hi danny,

Thanks!

When i use the same code with my values in it, it says "(FOC198) FATAL ERROR IN DATABASE I/O" - error. I have given a correct location for the .FOC file.

But code works fine without the DATASET command.
Even I am able to see the output when i use the TABLE FILE inside the same proc.

But why am i not able to see the output when i use the file in another proc? I want to physically store that data file in UNIX. How could i achieve this?


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
 
Posts: 23 | Registered: July 02, 2008Report This Post
Expert
posted Hide Post
Try doing a CREATE FILE filename before the MODIFY.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Virtuoso
posted Hide Post
But beware: when you do a CREATE file, the file will be written in the temporary directory. If you want it to be stored somewhere else, issue a APP HOLD before doing the create, in your case a APP HOLD BASEAPP.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
While what GamP says is generally true, but because he has a DATASET parameter in his master, the file will go there.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Virtuoso
posted Hide Post
Vasantha,

So you discarded the DATASET attribute. That's OK. Now you have to tell WF where to put the database. For that 2 things:
1. You use the USE command
2. You must have write permission to the directory where you want to write the focus database.

USE 
[pathname]/NUM.FOC NEW
END
CREATE FILE NUM
MODIFY FILE NUM
FREEFORM NUM
MATCH NUM
ON NOMATCH INCLUDE
ON MATCH REJECT
DATA
-REPEAT #VASA FOR &I FROM 1 TO 100;
NUM=&I ,$
-#VASA
END


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Member
posted Hide Post
Thanks danny!

It works.. Smiler


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
 
Posts: 23 | Registered: July 02, 2008Report This Post
Member
posted Hide Post
[SOLVED]Originally posted by Vasantha kumar:
Thanks danny!

It works.. Smiler[/QUOTE]


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
 
Posts: 23 | Registered: July 02, 2008Report 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] on data source

Copyright © 1996-2020 Information Builders