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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
IF GOTO
 Login/Join
 
Gold member
posted
Hi,

Is there a workaround to do the following using IF THEN GOTO

IF &OUTPUT EQ 'HTML' THEN GOTO A1 and A2 and A3
ELSE IF &OUTPUT EQ 'EXL2K' THEN GOTO A1 and A3

A1,A2,A3 are the three labels for three reports in the procedure. I want to skip the graph if the output option is EXL2K. Please help.

Thank you,
KK


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Expert
posted Hide Post
I would have this:

-A1
blah
blah
blah

-A2
-IF &OUTPUT EQ 'EXL2K' GOTO A3;
blah
blah
blah

-A3
blah
blah
blah


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
Francis,
I tried your approach but its just displaying the third report. Its skipping the first two reports for all the formats.

Is there any other approach or do you think I am missing something.

Thank you,
KK


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Expert
posted Hide Post
This sounds like a compound report, are you using the compound report syntax to OPEN the compound report, create the reports and then before the last report, CLOSE the compound report?


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
No this is not a compound report. This is a regular report with 3 fexs (2 reports and 1 graph).

Thanks,
KK.


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Virtuoso
posted Hide Post
If you want it to run more than 1 fex..then it becomes a compound report.


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Member
posted Hide Post
As Francis suggested but missed the -RUN command i.e.


-A1
blah
blah
blah
-RUN

-A2
-IF &OUTPUT EQ 'EXL2K' GOTO A3;
blah
blah
blah
-RUN

-A3
blah
blah
blah



Hope this works for you...

Allan


Webfocus 4.3.6
Windows XP
Reporting against Oracle Data and various Mainframe data (Adabas etc), ODBC to Excel/Access etc.
 
Posts: 2 | Registered: November 08, 2006Report This Post
Expert
posted Hide Post
Good catch Allan! I usually never forget the -RUN statement, even in a non-working example.


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
Virtuoso
posted Hide Post
Unless you use the SET COMPOUND=(OPEN/CLOSE) syntax, your code cannot create more than one report in excel format. Should work OK with HTML. Try using -SET &ECHO=ALL; and then view source to set what exactly is being run.


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
Virtuoso
posted Hide Post
Francis, Allan,

I would love to know what difference a -RUN will make to this process.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Gold member
posted Hide Post
Thank you all for your suggestions. Allan I already added -RUN but whats happening is, if the output format is HTML it runs A1 and A3 reports but when I change it EXL2K or PDF, it runs only the first report A1.

Please advise.

Thanks,
KK


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
Virtuoso
posted Hide Post
Have you Added the Compound report info as mentioned?


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Expert
posted Hide Post
SET COMPOUND = OPEN
-RUN

-A1
blah
blah
blah
-RUN

-A2
-IF &OUTPUT EQ 'EXL2K' GOTO A3;
blah
blah
blah
-RUN

-A3
SET COMPOUND = CLOSE
-RUN

blah
blah
blah
-RUN


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
Member
posted Hide Post
OK - Alan B you were correct the -RUN makes no real differnce. That annoyed me so I had to solve it with a sample.

KK as a few post allude to you need to be clear if you want a compound report or three different reports. I have solved for three different reports (at least it works in 4.3.6) see code below.

If &OUTPUT is anything but EXCEL then the HTML report will run, and all reports are in HTML format. If set to EXCEL as below than the first and last procedures will run in excel format.

This may (or may not!) solve your problem.

If you are after a compound report I will see what I can do.


Allan



-* File CAR.FEX

-SET &OUTPUT = 'EXCEL';
-SET &OUTPUTTYPE = IF &OUTPUT EQ 'EXCEL' THEN 'ON TABLE SET ONLINE-FMT EXL2K'
-ELSE 'ON TABLE SET ONLINE-FMT HTML';


TABLE FILE CAR
SUM CNT.CAR
BY COUNTRY

&OUTPUTTYPE.EVAL

END

-IF &OUTPUT EQ 'EXCEL' THEN GOTO SKIPHTML

TABLE FILE CAR
SUM CNT.MODEL
BY CAR

ON TABLE SET ONLINE-FMT HTML

END

-SKIPHTML

TABLE FILE CAR
SUM AVE.RETAIL_COST
BY COUNTRY

&OUTPUTTYPE.EVAL

END


Webfocus 4.3.6
Windows XP
Reporting against Oracle Data and various Mainframe data (Adabas etc), ODBC to Excel/Access etc.
 
Posts: 2 | Registered: November 08, 2006Report This Post
Gold member
posted Hide Post
Darin,

You are right ! I used the compound report syntax and it perfectly.

Thank you everyone for your great and valuable suggestions.

KK.


Test - Webfocus 7.6.7
Prod - Webfocus 7.6.7
Win2003
Sql Server 2000 and 2008
 
Posts: 59 | Registered: May 01, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders