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     Can use EX command within "TABLE...END" block?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Can use EX command within "TABLE...END" block?
 Login/Join
 
Gold member
posted
Hi,

Is it possible to use the EX command within a "TABLE...END" block?

Instead of

EX addReportInfo

TABLE
.
.
.
.
END

can I do


TABLE
.
.
.
EX addReportInfo
.
.
.
END

If so, where is the appropriate location for the EX command - after TABLE, after BY, after WHERE, after ON TABLE, etc?

I've tried without success.

Thanks,
George


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 70 | Registered: April 27, 2012Report This Post
Virtuoso
posted Hide Post
You cannot use the EXEC command, but you can use -INCLUDE.


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Gold member
posted Hide Post
Thanks. I thought about that and I'm thinking the contents of the INCLUDEd file must follow the syntax at the location of the file it's included into, as if it was originally written as part of that file.

In other words, if I do this

TABLE...
PRINT...
EX addReportInfo
.
BY...
WHERE...
AND...
ON TABLE...
END

the INCLUDEd file, addReportInfo, can only have commands allowed between PRINT and BY - it cannot have a TABLE or WHERE command.
Does that sound correct?

Thanks,
George


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 70 | Registered: April 27, 2012Report This Post
Virtuoso
posted Hide Post
The -INCLUDEd focexec can contain any of the commands allowed in a TABLE FILE request, including the TABLE FILE and END statements themselves. But after the parser has replaced the -INCLUDE with the statements in the focexec, the resulting code must be complete and proper.


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Gold member
posted Hide Post
Ok,

It sound like you're agreeing...

quote:
the INCLUDEd file must follow the syntax at the location of the file it's included into, as if it was originally written as part of that file.


In that case, I would need to rewrite the EX file to work properly as an INCLUDE file, resulting in 2 files, since the EX already works fine in other places. I need to research other alternatives.

Thanks,
George


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 70 | Registered: April 27, 2012Report This Post
Expert
posted Hide Post
You might like to tell us what you want to achieve with this program and the EX - perhaps a Dialog Manager loop is what you need...


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Gold member
posted Hide Post
I have a report header generated through a .fex file specifically written for that purpose. for TABLE...END blocks generating a single report page, there is no issues - treat as a compound report, just run the EX first followed by the TABLE...END block. But I wish to use this same header for each page of a multi-page report generated using a TABLE...END bloc. That's why I was hoping I could stick the EX inside the TABLE...END block.


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 70 | Registered: April 27, 2012Report This Post
Virtuoso
posted Hide Post
You also might want to try executing the procedure first and writing the results (formatted contents of heading lines) out to a file. Then you can just -INCLUDE that file as Dan indicated.


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Gold member
posted Hide Post
Darin:

Interesting.

I've always thought of INCLUDEing as inserting source code as if it was originally part of the recipient file. But it sound like you're saying the item to be INCLUDEd does not necessarily have to be source code (text), but as in my case, can be PDF output which is what my EX file produces. Am I understanding you correctly?

Thanks.


WebFOCUS 7.6
Windows, All Outputs
 
Posts: 70 | Registered: April 27, 2012Report This Post
Virtuoso
posted Hide Post
What Darin tried to make clear, is that you can have parts of your table command generated beforehand, which can then be -INCLUDEd into you TABLE fex. Like (parts of) the heading, WHERE fields, style sheet lines and such.
Mind you, it all has to be plain readable code that fits into the curernt command syntax...
So your initial thought is correct: INCLUDEing is inserting source code as if it was originally part of the recipient file.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report 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     Can use EX command within "TABLE...END" block?

Copyright © 1996-2020 Information Builders