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     [CLOSED] how to combine the column header

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] how to combine the column header
 Login/Join
 
Gold member
posted
Hi All,
We have a requirement to combine the 4 columns header .Please refer below for the requirment.

col1 |combined coluns | col7
|col2 col3 col4 col5 col6 |

Could you please let me know, How to reach this requirement.


Thanks,
Raghu

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


WebFOCUS 7.6.7
Windows
Excel, PDF, HTML
 
Posts: 56 | Registered: February 04, 2010Report This Post
Virtuoso
posted Hide Post
Not quite sure what you are looking for. Maybe you could give us an example? You can name a column title anything you want with the AS phrase.


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
Master
posted Hide Post
Are you looking for COLSPAN option. This working only in HTML & EXL2k.
Provide a example using car file to help you better. Also mention the output format.
 
Posts: 542 | Location: Dearborn, MI | Registered: June 03, 2009Report This Post
Expert
posted Hide Post
Raghu, to keep the spaces in the post put the text into the code tags.
col1 |combined coluns             | col7
     |col2  col3 col4 col5 col6   | 


As Ram says, you could use COLSPAN.

TABLE FILE CAR
HEADING
" "
" <+0>Sales Details<+0> "
 PRINT CAR         AS 'Car'
       MODEL       AS 'Model'
       BODYTYPE    AS 'Body Type'
       SEATS       AS 'No of Seats'
       DEALER_COST AS 'Dealer $'
       RETAIL_COST AS 'Retail $'
       SALES       AS 'Sales'
       MPG         AS 'MPG'

ON TABLE SET STYLE *
 TYPE=REPORT, HEADALIGN=BODY, $
 TYPE=HEADING, LINE=2, ITEM=1, COLSPAN=4, $
 TYPE=HEADING, LINE=2, ITEM=2, COLSPAN=3, $
 TYPE=HEADING, LINE=2, ITEM=3, COLSPAN=1, $
 TYPE=HEADING, LINE=1, COLSPAN=8, $
ENDSTYLE

END



This will depend on the output format. PDF does not like COLSPAN.

You could also use the WIDTH option.
TABLE FILE CAR
HEADING
" "
" <+0>|<+0>Sales Details<+0>|<+0> "
 PRINT CAR         AS 'Car'
       MODEL       AS 'Model'
       BODYTYPE    AS 'Body Type'
       SEATS       AS 'No of Seats'
       DEALER_COST AS 'Dealer $'
       RETAIL_COST AS 'Retail $'
       SALES       AS 'Sales'
       MPG         AS 'MPG'

ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
 TYPE=REPORT, COLUMN=N1, WRAP=1, $
 TYPE=REPORT, COLUMN=N2, WRAP=1, $
 TYPE=REPORT, COLUMN=N3, WRAP=1, $
 TYPE=REPORT, COLUMN=N4, WRAP=1, $
 TYPE=REPORT, COLUMN=N5, WRAP=1, $
 TYPE=REPORT, COLUMN=N6, WRAP=1, $
 TYPE=REPORT, COLUMN=N7, WRAP=1, $
 TYPE=REPORT, COLUMN=N8, WRAP=1, $
 TYPE=HEADING, LINE=2, ITEM=1, WIDTH=4.44, $
 TYPE=HEADING, LINE=2, ITEM=3, WIDTH=3.15,JUSTIFY=CENTER, $
ENDSTYLE

END


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
Gold member
posted Hide Post
Hi Waz,
We tried with the above code but it is not working.
The requirement is same as you mentioned in the above mail.
Please find below my code.
TABLE FILE RPTTOP
HEADING
" "
" <+0>Total Cost of Quality (USD)<+0> "
PRINT SUPLLIER_CODE AS 'Supplier Code'
SUPPLIER_NAME AS 'Supplier Name'
UNCOLLECTED AS 'Total Uncollected CRA(USD)'
DEL_COQ1 AS 'Delivery'
LCH_COQ1 AS 'Launch'
PRD_COQ1 AS 'Quality'
WAR_COQ1 AS 'Warranty'
REC_AMOUNT1 NOPRINT
COMPUTE CRA_P/D10.1% = (COLL_AMT1/REC_AMOUNT1)*100; AS '% CRA Collected'
COMPUTE COQ_1/D10.1 = PRD_COQ1+DEL_COQ1+WAR_COQ1+LCH_COQ1; NOPRINT
COMPUTE COQ_P/D10.1% = (COLL_AMT1/COQ_1)*100; AS '% COQ Collected'
ON TABLE SET PAGE-NUM NOLEAD
&HTML_VW
ON TABLE SET NODATA '0'
ON TABLE SET EMPTYCELLS OFF
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
TOPMARGIN=1,

TYPE=REPORT, HEADALIGN=BODY, $
TYPE=HEADING, LINE=2, ITEM=1, COLSPAN=4, $
TYPE=HEADING, LINE=2, ITEM=2, COLSPAN=3, $
TYPE=HEADING, LINE=2, ITEM=3, COLSPAN=1, $
TYPE=HEADING, LINE=2, ITEM=4, COLSPAN=1, $
TYPE=HEADING, LINE=1, COLSPAN=9, $

$
TYPE=REPORT,
BORDER-TOP=LIGHT,
BORDER-BOTTOM=LIGHT,
BORDER-LEFT=LIGHT,
BORDER-RIGHT=LIGHT,
BORDER-TOP-COLOR='SILVER',
BORDER-BOTTOM-COLOR='SILVER',
BORDER-LEFT-COLOR='SILVER',
BORDER-RIGHT-COLOR='SILVER',
GRID=ON,
FONT='ARIAL',
SIZE=9,
$
-IF HTML EQ 'EXL2K' THEN GOTO SKIP_TIT;
TYPE=TITLE,GRID=OFF,SIZE=9,BACKCOLOR=RGB(224 224 224),STYLE=BOLD,JUSTIFY=CENTER,
$
-SKIP_TIT
-IF HTML NE 'EXL2K' THEN GOTO SKIP_SLBR;
-SKIP_SLBR
TYPE=TITLE,STYLE=BOLD,JUSTIFY=CENTER,$
TYPE=TABHEADING,SIZE=12,STYLE=BOLD,$
TYPE=TABFOOTING,SIZE=12,STYLE=BOLD,$
TYPE=SUBHEAD,SIZE=10,STYLE=BOLD,$
TYPE=SUBFOOT,SIZE=10,STYLE=BOLD,$
-IF HTML EQ 'EXL2K' THEN GOTO SKIP_ACBG;
TYPE=ACROSSVALUE,SIZE=9,STYLE=BOLD,BACKCOLOR=RGB(224 224 224),$
TYPE=REPORT,COLUMN=N1,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N2,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N3,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N4,WIDTH =0.5,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N5,WIDTH =0.5,SQUEEZE=1,$
TYPE=DATA,COLUMN=N2,JUSTIFY=CENTER,WIDTH =2,$
TYPE=DATA,COLUMN=N3,JUSTIFY=LEFT,$
TYPE=DATA,COLUMN=N4,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N5,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N6,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N7,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N8,JUSTIFY=CENTER,$
-SKIP_ACBG
-IF HTML NE 'EXL2K' THEN GOTO SKIP_ACBR;
-SKIP_ACBR
-IF HTML NE 'EXL2K' THEN GOTO SKIP_STYL;
-SKIP_STYL
ENDSTYLE
END

Please advice me how can i reach the requirement

Thanks,
Raghu


WebFOCUS 7.6.7
Windows
Excel, PDF, HTML
 
Posts: 56 | Registered: February 04, 2010Report This Post
Gold member
posted Hide Post
MY IDEA:
  

TABLE FILE TEST1
PRINT 
COLUMN1
COLUMN2
COLUMN3
COLUMN4
COMPUTE combinedColumn1/A50 = COLUMN1||COLUMN2||COLUMN3
ON TABLE HOLD FORMAT TEST2


TABLE FILE TEST2
PRINT 
    *
HEADING
"<COLUMN1<combinedColumn1<COLUMN2 "
FOOTING
""
ON TABLE SET PAGE-NUM OFF 
ON TABLE NOTOTAL
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
     UNITS=IN,
     SQUEEZE=ON,
     ORIENTATION=PORTRAIT,
$
.......
.......
.......



i'm not sure this can run well,just a idea for you !

Thanks,
James Yang


WebFOCUS 7.6.8
WebFOCUS 7.6.10
BI
FLEX
.NET
 
Posts: 97 | Registered: August 18, 2009Report This Post
Gold member
posted Hide Post
Hi Yang,
We are not concatinating the data.
Just we are combinig the column header.

Thanks,
Raghu


WebFOCUS 7.6.7
Windows
Excel, PDF, HTML
 
Posts: 56 | Registered: February 04, 2010Report This Post
Master
posted Hide Post
You will have to do this as a heading or subheading rather than a title and include the whole line.
HEADING
"This is your company heading"
"The next line is your column titles"
"<+0>Col 1<+0> Col2 Col3 Col4 <+0> Col 5"

In your stylesheet
TYPE=HEADING,
LINE=3
ITEM=2,
COLSPAN=3,
JUSTIFY=CENTER,
$
If you have a problem identifying the item numbers, try making them different colors"


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
Raghu, what was wrong with the output ?

I changed your code to work on the CAR file, and it looks OK.

TABLE FILE CAR
HEADING
" "
" <+0>Total Cost of Quality (USD)<+0> "
PRINT COUNTRY AS 'Supplier Code'
CAR AS 'Supplier Name'
MODEL AS 'Total Uncollected CRA(USD)'
RETAIL_COST AS 'Delivery'
DEALER_COST AS 'Launch'
SALES AS 'Quality'
WIDTH AS 'Warranty'
LENGTH NOPRINT
COMPUTE CRA_P/D10.1% = (HEIGHT/LENGTH)*100; AS '% CRA Collected'
COMPUTE COQ_1/D10.1 = SALES +RETAIL_COST +WIDTH+DEALER_COST ; NOPRINT
COMPUTE COQ_P/D10.1% = (HEIGHT/COQ_1)*100; AS '% COQ Collected'
ON TABLE SET PAGE-NUM NOLEAD
-*&HTML_VW
ON TABLE SET NODATA '0'
ON TABLE SET EMPTYCELLS OFF
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
TOPMARGIN=1,

TYPE=REPORT, HEADALIGN=BODY, $
TYPE=HEADING, LINE=2, ITEM=1, COLSPAN=4, $
TYPE=HEADING, LINE=2, ITEM=2, COLSPAN=3, $
TYPE=HEADING, LINE=2, ITEM=3, COLSPAN=1, $
TYPE=HEADING, LINE=2, ITEM=4, COLSPAN=1, $
TYPE=HEADING, LINE=1, COLSPAN=9, $

$
TYPE=REPORT,
BORDER-TOP=LIGHT,
BORDER-BOTTOM=LIGHT,
BORDER-LEFT=LIGHT,
BORDER-RIGHT=LIGHT,
BORDER-TOP-COLOR='SILVER',
BORDER-BOTTOM-COLOR='SILVER',
BORDER-LEFT-COLOR='SILVER',
BORDER-RIGHT-COLOR='SILVER',
GRID=ON,
FONT='ARIAL',
SIZE=9,
$
-*-IF HTML EQ 'EXL2K' THEN GOTO SKIP_TIT;
TYPE=TITLE,GRID=OFF,SIZE=9,BACKCOLOR=RGB(224 224 224),STYLE=BOLD,JUSTIFY=CENTER,
$
-SKIP_TIT
-*-IF HTML NE 'EXL2K' THEN GOTO SKIP_SLBR;
-SKIP_SLBR
TYPE=TITLE,STYLE=BOLD,JUSTIFY=CENTER,$
TYPE=TABHEADING,SIZE=12,STYLE=BOLD,$
TYPE=TABFOOTING,SIZE=12,STYLE=BOLD,$
TYPE=SUBHEAD,SIZE=10,STYLE=BOLD,$
TYPE=SUBFOOT,SIZE=10,STYLE=BOLD,$
-*-IF HTML EQ 'EXL2K' THEN GOTO SKIP_ACBG;
TYPE=ACROSSVALUE,SIZE=9,STYLE=BOLD,BACKCOLOR=RGB(224 224 224),$
TYPE=REPORT,COLUMN=N1,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N2,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N3,WIDTH =1,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N4,WIDTH =0.5,SQUEEZE=1,$
TYPE=REPORT,COLUMN=N5,WIDTH =0.5,SQUEEZE=1,$
TYPE=DATA,COLUMN=N2,JUSTIFY=CENTER,WIDTH =2,$
TYPE=DATA,COLUMN=N3,JUSTIFY=LEFT,$
TYPE=DATA,COLUMN=N4,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N5,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N6,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N7,JUSTIFY=CENTER,$
TYPE=DATA,COLUMN=N8,JUSTIFY=CENTER,$
-SKIP_ACBG
-*-IF HTML NE 'EXL2K' THEN GOTO SKIP_ACBR;
-SKIP_ACBR
-*-IF HTML NE 'EXL2K' THEN GOTO SKIP_STYL;
-SKIP_STYL
ENDSTYLE
END


Is the problem the lines in the heading ?


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
Gold member
posted Hide Post
Smiler

i think Waz 's way is correct!

Thanks,
James Yang


WebFOCUS 7.6.8
WebFOCUS 7.6.10
BI
FLEX
.NET
 
Posts: 97 | Registered: August 18, 2009Report 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     [CLOSED] how to combine the column header

Copyright © 1996-2020 Information Builders