Jump to content
The ibi Community has moved to a new platform: Please Sign In and choose Forgot Password to continue

Is it possible to add an additional row underneath the 'day' on X axis that further defines the Month & Year


Merin Joseph
Go to solution Solved by David Beagan ,

Recommended Posts

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:image.png.f5f8a1c38e7b50555372db7a66c4c45c.pngcode

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

Here's one way:

image.thumb.png.759195c10ba869043690d5beb9c3ef9e.png

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

  • Solution

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

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...