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]Need to display ACROSS column exactly above BY Field

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED]Need to display ACROSS column exactly above BY Field
 Login/Join
 
Guru
posted
Hi All,

I'm new to Development not to the WebFOCUS. Hope, you all help me to get rid from this.

How do i display ACROSS column name(CAR) exactly above BY column name(COUNTRY) in EXCEL Report?

CAR ALFA ROMEO AUDI BMW DATSUN JAGUAR JENSEN MASERATI PEUGEOT TOYOTA TRIUMPH
COUNTRY
ENGLAND 18,621 14,940 4,292
FRANCE 4,631
ITALY 16,235 25,000
JAPAN 2,626 2,886
W GERMANY 5,063 49,500

This is my first query gonna post in FOCAL point. I'd really like to appreciate this forum, which helps much in WF report development.

Thanks,
Rifaz

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


-Rifaz

WebFOCUS 7.7.x and 8.x
 
Posts: 406 | Location: India | Registered: June 13, 2013Report This Post
Virtuoso
posted Hide Post
Rifaz,

Try this:
SET ACROSSTITLE = SIDE
TABLE FILE CAR
SUM
     SALES
BY  LOWEST COUNTRY
ACROSS CAR
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
 include=endeflt, $
type=report, border=light, $
TYPE=DATA,
     ACROSSCOLUMN=N8,
     BORDER-TOP=LIGHT,
     BORDER-BOTTOM=LIGHT,
     BORDER-LEFT=LIGHT,
     BORDER-RIGHT=LIGHT,
$
TYPE=ACROSSVALUE,
     ACROSS=1,
     BORDER-TOP=LIGHT,
     BORDER-BOTTOM=LIGHT,
     BORDER-LEFT=LIGHT,
     BORDER-RIGHT=LIGHT,
$
ENDSTYLE
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
Expert
posted Hide Post
quote:
SET ACROSSTITLE = SIDE


Awesome command.

But I think it came in in 7.7


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
Silver Member
posted Hide Post
7704 ACROSSTITLE = option ..... control location of ACROSS field titles in PDF, EXL2K, EXL07, and HTML output
7701 option: ABOVE [default] titles are displayed above the values
7701 option: SIDE titles are displayed to the left of the values
From the WebFocus Keysheet - see Aviter.com

First available in 7.7.01. Excel and HTML output added in 7.7.04

This message has been edited. Last edited by: John W Price,



WebFOCUS 8.0.2, FOCUS since 1977 - John@Aviter.com
PDF , Excel, FOCUS, Author of the Keysheets and Dates book.
www.Aviter.com
 
Posts: 40 | Registered: April 19, 2013Report This Post
Guru
posted Hide Post
Thanks much Daniel and John!!!. But, still we're in 7611, is there any possible workaround for this? Titles can be a STATIC.


-Rifaz

WebFOCUS 7.7.x and 8.x
 
Posts: 406 | Location: India | Registered: June 13, 2013Report This Post
Expert
posted Hide Post
An option is to convert the across field to columns.

One way to the use the across and HOLD the output. Then it get a bit tricky, as the number of fields becomes dymanic.

Have a look at what happens when you hold a TABLE request with an ACROSS.


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
Rifaz,

A 7.6 approach:
  
TABLE FILE CAR
BY CAR
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE HOLD AS CC
END
-RUN
-SET &CARS=&LINES;
DEFINE FILE CAR
-REPEAT #CARSALES FOR &I FROM 1 TO &CARS;
-READFILE CC
-SET &CAR.&I='&CAR.EVAL';
SALES&I=IF CAR EQ '&CAR.&I' THEN SALES ELSE 0;
-#CARSALES
END
-CLOSE CC
TABLE FILE CAR
SUM
-SET &HEAD='CAR';
-REPEAT #SALES FOR &I FROM 1 TO &CARS;
    SALES&I AS ''
-SET &HEAD=&HEAD | '<+0>' | &CAR.&I.EVAL;
-#SALES
BY  COUNTRY AS 'COUNTRY'
HEADING
"&HEAD"
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
 include=endeflt, $
type=report, border=light, $
TYPE=HEADING, HEADALIGN=BODY,$
TYPE=DATA,
     ACROSSCOLUMN=N8,
     BORDER-TOP=LIGHT,
     BORDER-BOTTOM=LIGHT,
     BORDER-LEFT=LIGHT,
     BORDER-RIGHT=LIGHT,
$
TYPE=ACROSSVALUE,
     ACROSS=1,
     BORDER-TOP=LIGHT,
     BORDER-BOTTOM=LIGHT,
     BORDER-LEFT=LIGHT,
     BORDER-RIGHT=LIGHT,
$
ENDSTYLE
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
Guru
posted Hide Post
Thanks Danny,

I will try reproduce in my house using the real datas and let you know.

Danny, I'm still wondering, how did he do that? You rocked really!!! Smiler

Hoping, i'm going to attain developing the report as desired.

Thanks,
Rifaz


-Rifaz

WebFOCUS 7.7.x and 8.x
 
Posts: 406 | Location: India | Registered: June 13, 2013Report This Post
Guru
posted Hide Post
Thanks Danny,

Somehow, customer said, ok with this report.
Good news is that,soon, we're going to migrate to 80x. from 7.6.11 Smiler. So, i use John & Waz suggestion at ease to create report.

I'm going to close this post as solved.

Happy Weekend!!!

Thanks,
Rifaz


-Rifaz

WebFOCUS 7.7.x and 8.x
 
Posts: 406 | Location: India | Registered: June 13, 2013Report This Post
Platinum Member
posted Hide Post
Thanks. I got the same problem and this helps.


WebFOCUS 7.7.03
Windows, All Outputs
 
Posts: 125 | Registered: June 17, 2013Report 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]Need to display ACROSS column exactly above BY Field

Copyright © 1996-2020 Information Builders