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]WF 8201 App Studio Graph Issue

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED]WF 8201 App Studio Graph Issue
 Login/Join
 
Guru
posted
I need to know how to run this graph with the dates displaying in lowest to highest order (Jan 16 - Dec 16) and not alphabetical order.
I also do not need the legend to display at the bottom. Thanks.
-SET &ECHO = ALL;

DEFINE FILE CAR
MTH_NAME/A3 = DECODE MODEL (
'V12XKE AUTO'               'Jan'
'XJ12L AUTO'                'Feb'
'INTERCEPTOR III'           'Mar'
'TR7'                       'Apr'
'B210 2 DOOR AUTO'          'May'
'COROLLA 4 DOOR DIX AUTO'   'Jun'
'2000 4 DOOR BERLINA'       'Jul'
'2000 GT VELOCE'            'Aug'
'2000 SPIDER VELOCE'        'Sep'
'DORA 2 DOOR'               'Oct'
'100 LS 2 DOOR AUTO'        'Nov'
'2002 2 DOOR'               'Dec'
ELSE '');
-*
RPT_YR/A2       = '16';
RPT_MO/I2       = DECODE MTH_NAME (
'Jan'            01
'Feb'            02
'Mar'            03
'Apr'            04
'May'            05
'Jun'            06
'Jul'            07
'Aug'            08
'Sep'            09
'Oct'            10
'Nov'            11
'Dec'            12 ELSE 0);
REPORT_MY/A8    = MTH_NAME|''|RPT_YR;
MONTH1/A10      = 'Jan 16';
MONTH2/A10      = 'Feb 16';
MONTH3/A10      = 'Mar 16';
MONTH4/A10      = 'Apr 16';
MONTH5/A10      = 'May 16';
MONTH6/A10      = 'Jun 16';
MONTH7/A10      = 'Jul 16';
MONTH8/A10      = 'Aug 16';
MONTH9/A10      = 'Sep 16';
MONTH10/A10     = 'Oct 16';
MONTH11/A10     = 'Nov 16';
MONTH12/A10     = 'Dec 16';
COMPANY/A3 WITH CAR = 'ABC';
SOFTWARE/A2 WITH CAR = 'WF';
RPT_CONTENT/A3 WITH CAR = 'BOB';
END
GRAPH FILE CAR
SUM
COMPUTE COST_PER_SEAT/D20CM = RCOST / SEATS; AS ''
-*ACROSS REPORT_MY COLUMNS MONTH1 AND MONTH2 AND MONTH3 AND MONTH4 AND MONTH5 AND MONTH6 AND MONTH7 AND MONTH8 AND MONTH9 AND MONTH10 AND MONTH11 AND MONTH12
BY RPT_CONTENT NOPRINT
BY COMPANY NOPRINT
BY SOFTWARE NOPRINT
BY RPT_YR NOPRINT
BY RPT_MO NOPRINT
ACROSS REPORT_MY AS ''
WHERE MTH_NAME NE ''
ON GRAPH PCHOLD FORMAT PDF
ON GRAPH SET GRMERGE ON
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 5
ON GRAPH SET GRXAXIS 0
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET STYLE *
*GRAPH_JS
border:{width:2, color:'teal'},
legend: {visible:false},
  colorMode: {mode: 'byGroup'},
series: [
   {series: 'all', border: {width: 1, color: 'grey'}},
   {series: 0, color: 'red'},
   {series: 1, color: 'teal'},
   {series: 2, color: 'yellow'},
   {series: 3, color: 'cyan'}
]
*END
ENDSTYLE
END


This message has been edited. Last edited by: Michele Brooks,


WF 8205, Windows 10
Oracle DBMS
EXL07/PDF Output
 
Posts: 244 | Registered: August 27, 2012Report This Post
Virtuoso
posted Hide Post
Hi Michelle

Try this.


-SET &ECHO = ALL;

DEFINE FILE CAR
MTH_NAME/A3 = DECODE MODEL (
'V12XKE AUTO' 'Jan'
'XJ12L AUTO' 'Feb'
'INTERCEPTOR III' 'Mar'
'TR7' 'Apr'
'B210 2 DOOR AUTO' 'May'
'COROLLA 4 DOOR DIX AUTO' 'Jun'
'2000 4 DOOR BERLINA' 'Jul'
'2000 GT VELOCE' 'Aug'
'2000 SPIDER VELOCE' 'Sep'
'DORA 2 DOOR' 'Oct'
'100 LS 2 DOOR AUTO' 'Nov'
'2002 2 DOOR' 'Dec'
ELSE '');
-*
RPT_YR/A2 = '16';
RPT_MO/I2 = DECODE MTH_NAME (
'Jan' 01
'Feb' 02
'Mar' 03
'Apr' 04
'May' 05
'Jun' 06
'Jul' 07
'Aug' 08
'Sep' 09
'Oct' 10
'Nov' 11
'Dec' 12 ELSE 0);
REPORT_MY/A8 = MTH_NAME|''|RPT_YR;
MONTH1/A10 = 'Jan 16';
MONTH2/A10 = 'Feb 16';
MONTH3/A10 = 'Mar 16';
MONTH4/A10 = 'Apr 16';
MONTH5/A10 = 'May 16';
MONTH6/A10 = 'Jun 16';
MONTH7/A10 = 'Jul 16';
MONTH8/A10 = 'Aug 16';
MONTH9/A10 = 'Sep 16';
MONTH10/A10 = 'Oct 16';
MONTH11/A10 = 'Nov 16';
MONTH12/A10 = 'Dec 16';
COMPANY/A3 WITH CAR = 'ABC';
SOFTWARE/A2 WITH CAR = 'WF';
RPT_CONTENT/A3 WITH CAR = 'BOB';
END
-*IA_GRAPH_BEGIN
-*Do not delete or modify the comments below
*-INTERNAL_COMMENT ACROSS REPORT_MY COLUMNS MONTH1 AND MONTH2 AND MONTH3 AND MONTH4 AND MONTH5 AND MONTH6 AND MONTH7 AND MONTH8 AND MONTH9 AND MONTH10 AND MONTH11 AND MONTH12
-*Do not delete or modify the comments above
-*Do not delete or modify the comments below
*-INTERNAL_COMMENT ACROSS REPORT_MY COLUMNS MONTH1 AND MONTH2 AND MONTH3 AND MONTH4 AND MONTH5 AND MONTH6 AND MONTH7 AND MONTH8 AND MONTH9 AND MONTH10 AND MONTH11 AND MONTH12
-*Do not delete or modify the comments above
-*Do not delete or modify the comments below
*-INTERNAL_COMMENT LINE#0$PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+DQo8IS0tMS4wLS0+PFJvb3QgdmVyc2lvbj0iMS4xIj4NCiAgICA8T2JqZWN0IG9iamVjdElkPSJDaGFydF8xIj4NCiAgICAgICAgPFByb3BlcnR5IG5hbWU9IkxpbmtlZFNvcnRzIiB0eXBlPSJqYXZhLmxhbmcuU3RyaW5nIi8+DQogICAgPC9PYmplY3Q+DQogICAgPE9iamVjdCBvYmplY3RJZD0iR0xPQkFMIj4NCiAgICAgICAgPFByb3BlcnR5IG5hbWU9IlNhbXBsZURhdGEiIHR5cGU9ImphdmEubGFuZy5Cb29sZWFuIj5mYWxzZTwvUHJvcGVydHk+DQogICAgICAgIDxQcm9wZXJ0eSBuYW1lPSJHbG9iYWxSZWNvcmRMaW1pdCIgdHlwZT0iamF2YS5sYW5nLlN0cmluZyI+NTAwPC9Qcm9wZXJ0eT4NCiAgICAgICAgPFByb3BlcnR5IG5hbWU9Ikdsb2JhbFJ1blJlY29yZExpbWl0IiB0eXBlPSJqYXZhLmxhbmcuU3RyaW5nIj4wPC9Qcm9wZXJ0eT4NCiAgICAgICAgPFByb3BlcnR5IG5hbWU9Ikdsb2JhbE9wdGltaXphdGlvbiIgdHlwZT0iamF2YS5sYW5nLkJvb2xlYW4iPnRydWU8L1Byb3BlcnR5Pg0KICAgICAgICA8UHJvcGVydHkgbmFtZT0iZmllbGREaXNwbGF5TW9kZSIgdHlwZT0iamF2YS5sYW5nLlN0cmluZyI+bGFiZWw8L1Byb3BlcnR5Pg0KICAgICAgICA8UHJvcGVydHkgbmFtZT0icHJlZml4RGlzcGxheU1vZGUiIHR5cGU9ImphdmEubGFuZy5TdHJpbmciLz4NCiAgICAgICAgPF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AgICAgICAgPEVudHJ5IGtleT0iQ0FSIiB0eXBlPSJqYXZhLmxhbmcuU3RyaW5nIj5NZXRhRGF0YVRyZWUuVklFV19ESU1TPC9FbnRyeT4NCiAgICAgICAgPC9Qcm9wZXJ0eT4NCiAgICAgICAgPFByb3BlcnR5IG5hbWU9ImVuYWJsZVByZXZpZXciIHR5cGU9ImphdmEubGFuZy5Cb29sZWFuIj50cnVlPC9Qcm9wZXJ0eT4NCiAgICA8L09iamVjdD4NCjwvUm9vdD4NCg==
-*Do not delete or modify the comments above
ENGINE INT CACHE SET ON
-DEFAULTH &WF_STYLE_UNITS='INCHES';
-DEFAULTH &WF_STYLE_HEIGHT='4.21875';
-DEFAULTH &WF_STYLE_WIDTH='8.020833';
-DEFAULTH &WF_TITLE='WebFOCUS Report';
GRAPH FILE CAR
-* Created by Info Assist for Graph
SUM COMPUTE COST_PER_SEAT/D20CM=RCOST/SEATS ; AS ''
BY CAR.COMP.RPT_CONTENT NOPRINT
BY CAR.COMP.COMPANY NOPRINT
BY CAR.COMP.SOFTWARE NOPRINT
BY RPT_YR NOPRINT
BY CAR.CARREC.RPT_MO NOPRINT
BY CAR.CARREC.REPORT_MY AS ''
WHERE CAR.CARREC.MTH_NAME NE '';
ON GRAPH PCHOLD FORMAT PDF
ON GRAPH SET VZERO OFF
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRWIDTH 1
ON GRAPH SET UNITS &WF_STYLE_UNITS
ON GRAPH SET HAXIS &WF_STYLE_WIDTH
ON GRAPH SET VAXIS &WF_STYLE_HEIGHT
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 6
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET STYLE *
*GRAPH_SCRIPT
setPieDepth(0);
setPieTilt(0);
setDepthRadius(0);
setCurveFitEquationDisplay(false);
setPlace(true);
*END
INCLUDE=IBFS:/FILE/IBI_HTML_DIR/javaassist/intl/EN/ENIADefault_combine.sty,$
TYPE=REPORT, TITLETEXT=&WF_TITLE.QUOTEDSTRING, $
*GRAPH_SCRIPT
setReportParsingErrors(false);
setSelectionEnableMove(false);
*GRAPH_JS
"border": {
"color": "teal",
"width": 2
},
"legend": {
"visible": false
},
"series": [{
"border": {
"color": "grey",
"width": 1
},
"series": "all"
}, {
"color": "red",
"series": 0
}, {
"color": "teal",
"series": 1
}, {
"color": "yellow",
"series": 2
}, {
"color": "cyan",
"series": 3
}],
"colorMode": {
"mode": "byGroup"
}
,
*END
ENDSTYLE
END
-RUN

-*IA_GRAPH_FINISH


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2127 | Location: Customer Support | Registered: April 12, 2005Report This Post
Virtuoso
posted Hide Post
Use a real date and not a text (or Chuck option but the NOPRINT fields may cause issue in graph).

Assuming that you have a real date somewhere in your data.

DEFINE FILE GGSALES
YM /MYt = DATE;
END
TABLE FILE GGSALES
SUM DOLLARS
BY YM
END


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report This Post
Guru
posted Hide Post
Chuck, your suggestion worked. Thanks so much. I applied the changes to my real
graph and it came out perfectly. I originally tried using the COLUMNS function that I used in 8009, but it doesn't work in 8201. I really appreciate your suggestions. Thanks again.


WF 8205, Windows 10
Oracle DBMS
EXL07/PDF Output
 
Posts: 244 | Registered: August 27, 2012Report This Post
Guru
posted Hide Post
quote:
Originally posted by MartinY:
Use a real date and not a text (or Chuck option but the NOPRINT fields may cause issue in graph).

Assuming that you have a real date somewhere in your data.

Thanks Martin, but I had no problem with the defined hard coded dates. Thanks for the example using the GGSALES DB. I'll keep that DB in mind when I need to use dates.

DEFINE FILE GGSALES
YM /MYt = DATE;
END
TABLE FILE GGSALES
SUM DOLLARS
BY YM
END


WF 8205, Windows 10
Oracle DBMS
EXL07/PDF Output
 
Posts: 244 | Registered: August 27, 2012Report 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]WF 8201 App Studio Graph Issue

Copyright © 1996-2020 Information Builders