Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » possible to have a dynamic date x axis
possible to have a dynamic date x axis [message #1058521] Tue, 14 May 2013 11:53 Go to next message
Darren Gipson is currently offline Darren GipsonFriend
Messages: 3
Registered: April 2013
Junior Member
I have a 3 series bar chart that I want to use to compare performance

my series are: cases opened, cases resolved, cases closed. (these are date fields)

I have this configured okay on y axis, no problem. but I have a problem with the x axis, as I dynamically want to set the start date to 7 days from now.

so that it shows something like this in graph form (sorry about the bad table):

Day------------Open-----Resolve-----Close
Wednesday 8th---4----------5----------2
Thursday 9th-----7----------8----------2
...

then if I run the report tomorrow it should show:

Day------------Open-----Resolve-----Close
Thursday 9th----7----------8----------2
Friday 10th------3----------6----------6
...

The problem I have is I don't know how to give an array of values to the axis. I tried something like this (I know that the dates are set, I was going to use some javascript to give them the correct rolling dates):

x = new Date ("2013/05/13");
y = new Date ("2013/05/12");
retVal = new Array(x, y);

but it doesn't work.

Anyone done any thing similar?
Re: possible to have a dynamic date x axis [message #1058775 is a reply to message #1058521] Wed, 15 May 2013 03:06 Go to previous messageGo to next message
Michael Williams is currently offline Michael WilliamsFriend
Messages: 1684
Registered: July 2009
Senior Member

So, you just want to automatically have the last seven days in the chart? Let me know.

Michael

Add interactivity, scheduling, sharing, live Excel export, and JS integration to your BIRT app with the new, free BIRT server, BIRT iHub F-Type.
Re: possible to have a dynamic date x axis [message #1058833 is a reply to message #1058775] Wed, 15 May 2013 10:22 Go to previous messageGo to next message
Darren Gipson is currently offline Darren GipsonFriend
Messages: 3
Registered: April 2013
Junior Member
yes
Re: possible to have a dynamic date x axis [message #1058961 is a reply to message #1058833] Thu, 16 May 2013 04:04 Go to previous message
Michael Williams is currently offline Michael WilliamsFriend
Messages: 1684
Registered: July 2009
Senior Member

You could just set a filter or limit your query using something like: BirtDateTime.addDay(BirtDateTime.today(),-6);

Michael

Add interactivity, scheduling, sharing, live Excel export, and JS integration to your BIRT app with the new, free BIRT server, BIRT iHub F-Type.
Previous Topic:don't want Parameters to be mandatory
Next Topic:URL Escape codes coming in chart x axis label
Goto Forum:
  


Current Time: Thu Dec 18 08:42:35 GMT 2014

Powered by FUDForum. Page generated in 0.09790 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software