Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] formatting acrossvalue to line up with column header
Go
New
Search
Notify
Tools
Reply
  
[SOLVED] formatting acrossvalue to line up with column header
 Login/Join
 
Silver Member
posted
Hi all,

I have read through the forums and can't find what I'm looking for, so I'll post my question.

I have code like this:

TABLE FILE CAR
SUM DEALER_COST
BY MODEL
ACROSS COUNTRY
END

I have added all sorts of options to the styling but one thing I can't do is move the values down one line. They want the Country values to show up on the same line as MODEL formatted as Excel.

When I do this in any format, HTML, EXL2K, I can't get the values down one line. I tried moving them down manually: (this is my code, not the car example)

ON SEGMENT SUBHEAD
"Production Year"
" "
"Segment<+0>2007<+0>2008<+0>2009<+0>2010<+0>2011<+0>2012<+0>2013<+0>2014<+0>2015<+0>2016<+0>2017"
ON TABLE SET PAGE NOLEAD
ON TABLE PCHOLD FORMAT EXL2K
ON TABLE SET STYLE *
TYPE=REPORT, SQUEEZE=ON, GRID=ON, FONT='ARIAL',$
TYPE=SUBHEAD, BORDER-TOP=MEDIUM, BORDER-LEFT=MEDIUM, BORDER-RIGHT=MEDIUM, STYLE=BOLD,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=1, POSITION=0.00, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=2, POSITION=P2, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=3, POSITION=P3, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=4, POSITION=P4, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=5, POSITION=P5, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=6, POSITION=P6, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=7, POSITION=P7, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=8, POSITION=P8, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=9, POSITION=P9, JUSTIFY=RIGHT,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=10, POSITION=P10, JUSTIFY=RIGHT,$

and I could get them to move down, but now they are all returned in 1 cell.

Any way to make this work?

Thanks!
Joy

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


7.7.2, Windows, html
 
Posts: 34 | Location: Minnesota | Registered: September 03, 2010Reply With QuoteReport This Post
Guru
posted Hide Post
Whenever you ACROSS you always get that extra line. It's kind of annoyance and most of the time customer understand. Looking at you code it looks like you are missing TYPE=SUBHEAD, HEADALIGN=BODY, $. Also you should add a COLSPAN=1, to your subhead items. POSITION is generally used in PDF output format not really used in Excel output format. Having it in the stylesheet doesn't hurt anything. Take a look at this.
  
DEFINE FILE CAR
SEGMENT/A1=''
END

TABLE FILE CAR
SUM
   DEALER_COST

BY SEGMENT NOPRINT
BY MODEL AS ''
ACROSS COUNTRY AS '' NOPRINT
ON SEGMENT SUBHEAD
"Production Year"
" "
"Segment<+0>2007<+0>2008<+0>2009<+0>2010<+0>2011<+0>2012<+0>2013<+0>2014<+0>2015<+0>2016<+0>2017"
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, SQUEEZE=ON, GRID=ON, FONT='ARIAL',$
TYPE=SUBHEAD, HEADALIGN=BODY,$
TYPE=SUBHEAD, BORDER-TOP=MEDIUM, BORDER-LEFT=MEDIUM, BORDER-RIGHT=MEDIUM, STYLE=BOLD,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=1,  POSITION=0.00, JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=2,  POSITION=P2,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=3,  POSITION=P3,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=4,  POSITION=P4,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=5,  POSITION=P5,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=6,  POSITION=P6,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=7,  POSITION=P7,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=8,  POSITION=P8,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=9,  POSITION=P9,   JUSTIFY=RIGHT, COLSPAN=1,$
TYPE=SUBHEAD, LINE=3, OBJECT=TEXT, ITEM=10, POSITION=P10,  JUSTIFY=RIGHT, COLSPAN=1,$
$
ENDSTYLE
END


WebFOCUS 8.1.05M Unix Self-Service/MRE/Report Caster - Outputs Excel, PDF, HTML, Flat Files
 
Posts: 320 | Location: Memphis, TN | Registered: February 12, 2008Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Joy, does this work for you?

 TABLE FILE CAR
SUM DEALER_COST
BY MODEL AS ''
ACROSS COUNTRY AS 'MODEL'
ON TABLE SET ACROSSTITLE SIDE
ON TABLE SET ACROSSLINE SKIP
ON TABLE SET PAGE NOLEAD
ON TABLE SET HTMLCSS ON
END
 


WebFOCUS 8.2.06
 
Posts: 193 | Location: Sterling Heights, Michigan | Registered: October 19, 2010Reply With QuoteReport This Post
Expert
posted Hide Post
Well, it should, shouldn't it?!

You've uncovered another amazing new (probably) v7.7 option I was not aware about!

That's three new options within a few days - ones that were not covered in a recent "New Features" session at the local IBI User Forum.


  • ACROSS Column title behaviour improvement
  • Set the default behaviour for date related language
  • -READFILE to read a file using the metadata instead of variable definitions


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, 2005Reply With QuoteReport This Post
Silver Member
posted Hide Post
Thanks everyone.

dbeagan yours does work, but in using CAR as my code sample I didn't add enough information, I have multiple BY columns and the users wants them because he's going to pivot the table in excel. So I have to show those coumn headings. I just need to move the ACROSS columns down.

I will tell them that for now they will have to manually remove them.


7.7.2, Windows, html
 
Posts: 34 | Location: Minnesota | Registered: September 03, 2010Reply With QuoteReport This Post
<FreSte>
posted
Hi,

If you are using the output using in Excel to pivot, maybe you can use this (as per manual)
It will create a pivot table for you:

TABLE FILE CAR
HEADING
"CAR File PivotTable"
"Sum of Sales by Car Across Model"
PRINT SALES
BY CAR
ACROSS MODEL
ON TABLE COLUMN-TOTAL
ON TABLE SET STYLE *
TYPE=HEADING, LINE=1, FONT='ARIAL', COLOR=PURPLE, SIZE=16, STYLE=BOLD,$
TYPE=HEADING, LINE=2, FONT='ARIAL', COLOR=PURPLE, SIZE=12, STYLE=BOLD,$
TYPE=DATA, FONT='ARIAL', COLOR=PURPLE,$
TYPE=GRANDTOTAL, FONT='ARIAL', COLOR=PURPLE, SIZE=16, STYLE=BOLD,$
ENDSTYLE
ON TABLE PCHOLD AS CARPIVOT FORMAT EXL2K PIVOT
PAGEFIELDS COUNTRY
CACHEFIELDS RETAIL_COST TYPE
END
 
Reply With QuoteReport This Post
Virtuoso
posted Hide Post
Or:
TABLE FILE CAR
SUM DEALER_COST AS ''
BY CAR 
BY MODEL
ACROSS COUNTRY
ON TABLE SET ASNAMES ON
ON TABLE HOLD
END
TABLE FILE HOLD
PRINT *
END


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1960 | Location: Netherlands | Registered: September 25, 2007Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] formatting acrossvalue to line up with column header

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.