Merin Joseph Posted September 1, 2023 Share Posted September 1, 2023 selection of dates is based up on webfocus date controls (combined) Link to comment Share on other sites More sharing options...
David Beagan Posted September 1, 2023 Share Posted September 1, 2023 If you can get two levels, why can't you get a third? What is your code like now? Link to comment Share on other sites More sharing options...
Merin Joseph Posted September 1, 2023 Author Share Posted September 1, 2023 no i just have only 1 level.. above is my requirement to get that 2nd level with month and year.. This is what i have now:code DEFINE FILE SHIPMENTS_HOLDSHIPDATE_DAY/I2 MISSING ON = DTPART(SHIPDATE_D, DAY);SHIPDATE_MONTH/I2 MISSING ON = DTPART(SHIPDATE_D, MONTH);SHIPDATE_YEAR/I4 MISSING ON = DTPART(SHIPDATE_D, YEAR);END GRAPH FILE SHIPMENTS_HOLDSUMQUANTITYINPRIMARY/D20.2C AS 'Quantity in Primary'-*BY SHIPDATE_DBY SHIPDATE_D NOPRINTBY SHIPDATE_DAY AS 'Day'BY SHIPDATE_MONTH AS 'Month'BY SHIPDATE_YEAR AS 'Year'HEADING----------------------------------------TYPE=DATA, COLUMN=N1, BUCKET=x-axis, $TYPE=DATA, COLUMN=N2, BUCKET=x-axis, $TYPE=DATA, COLUMN=N3, BUCKET=tooltip, $TYPE=DATA, COLUMN=N4, BUCKET=tooltip, $TYPE=DATA, COLUMN=N5, BUCKET=y-axis, $ Link to comment Share on other sites More sharing options...
David Beagan Posted September 1, 2023 Share Posted September 1, 2023 Here's one way: DEFINE FILE GGSALES AMP_YYMD/YYMD = &YYMD; DATE_YYMD/YYMD = AMP_YYMD - SEQ_NO + 1; DATE_YYMt/YYBMt = DATE_YYMD; DATE_D/D = DATE_YYMD; END GRAPH FILE GGSALESSUM UNITSBY DATE_YYMtBY DATE_DWHERE WHERE SEQ_NO FROM 50 TO 70HEADINGON GRAPH PCHOLD FORMAT JSCHARTON GRAPH SET VZERO OFFON GRAPH SET HTMLENCODE ONON GRAPH SET GRAPHDEFAULT OFFON GRAPH SET EMBEDHEADING ONON GRAPH SET GRMERGE ADVANCEDON GRAPH SET GRMULTIGRAPH 0ON GRAPH SET GRLEGEND 0ON GRAPH SET GRXAXIS 2ON GRAPH SET LOOKGRAPH VBARON GRAPH SET AUTOFIT ONON GRAPH SET STYLE *INCLUDE=IBFS:/FILE/IBI_HTML_DIR/ibi_themes/endeflt.sty,$ENDSTYLEEND Link to comment Share on other sites More sharing options...
Merin Joseph Posted September 1, 2023 Author Share Posted September 1, 2023 when i run this same code, it actually looks like this. Looks like it doesn't support in my version. Isn't it? Link to comment Share on other sites More sharing options...
Martin Yergeau Posted September 1, 2023 Share Posted September 1, 2023 Shouldn't be the case since I've run it under v8204 and I have the same result as David.Under which version are you Merin ? Link to comment Share on other sites More sharing options...
Solution David Beagan Posted September 1, 2023 Solution Share Posted September 1, 2023 Merin, this is more up-to-date coding, similar to how InfoAssist would do it. Does it work for you?DEFINE FILE ggsales AMP_YYMD/YYMD = &YYMD; DATE_YYMD/YYMD = AMP_YYMD - SEQ_NO + 1; DATE_YYMt/YYBMt = DATE_YYMD; DATE_D/D = DATE_YYMD; END GRAPH FILE ggsalesSUM UNITSBY DATE_YYMtBY DATE_DWHERE WHERE SEQ_NO FROM 50 TO 70ON GRAPH PCHOLD FORMAT JSCHARTON GRAPH SET VZERO OFFON GRAPH SET LOOKGRAPH BARON GRAPH SET AUTOFIT ONON GRAPH SET STYLE *TYPE=DATA, COLUMN=N1, BUCKET=x-axis, $TYPE=DATA, COLUMN=N2, BUCKET=x-axis, $TYPE=DATA, COLUMN=N3, BUCKET=y-axis, $*GRAPH_SCRIPTsetFillColor(getSeries(0),new Color(#5388be));setLabelStagger(getO1Label(),true);*GRAPH_JS_FINAL"xaxis": {"labels": {"nestingConcatSymbol": undefined}}*ENDENDSTYLEEND Link to comment Share on other sites More sharing options...
Merin Joseph Posted September 1, 2023 Author Share Posted September 1, 2023 YES... This one is working @David Beagan . You have a swift problem solving skill. Thank you soo much.. Link to comment Share on other sites More sharing options...
Merin Joseph Posted September 1, 2023 Author Share Posted September 1, 2023 v8207 Link to comment Share on other sites More sharing options...
David Beagan Posted September 1, 2023 Share Posted September 1, 2023 You are welcome. Link to comment Share on other sites More sharing options...
David Beagan Posted May 4 Share Posted May 4 Reposting this code solution so that it is readable and usable for anyone who may find this in the future: DEFINE FILE ggsales AMP_YYMD/YYMD = &YYMD; DATE_YYMD/YYMD = AMP_YYMD - SEQ_NO + 1; DATE_YYMt/YYBMt = DATE_YYMD; DATE_D/D = DATE_YYMD; END GRAPH FILE ggsales SUM UNITS BY DATE_YYMt BY DATE_D WHERE WHERE SEQ_NO FROM 50 TO 70 ON GRAPH PCHOLD FORMAT JSCHART ON GRAPH SET VZERO OFF ON GRAPH SET LOOKGRAPH BAR ON GRAPH SET AUTOFIT ON ON GRAPH SET STYLE * TYPE=DATA, COLUMN=N1, BUCKET=x-axis, $ TYPE=DATA, COLUMN=N2, BUCKET=x-axis, $ TYPE=DATA, COLUMN=N3, BUCKET=y-axis, $ *GRAPH_SCRIPT setFillColor(getSeries(0),new Color(#5388be)); setLabelStagger(getO1Label(),true); *GRAPH_JS_FINAL "xaxis": { "labels": { "nestingConcatSymbol": undefined } } *END ENDSTYLE END 2 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now