ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Discrete distributed dataset bar chart
Posted by jettaime on Aug-31-2012 18:06
Attachments:
Hi,

For simple explanation, I made an image which explain my purpose.
There is a bar chart.
This chart has multi layer in every x-axis.

Unfortunately, the dataset of every x-axis might be different each other.
For example,
in Mon, there are '172.16.1.100', '172.16.1.101' and '172.16.1.102'
in Tue, '172.16.1.102', '172.16.1.103' and '172.16.1.105'
in Wed,  '172.16.1.103', '172.16.1.104' and '172.16.1.106'
....


Actually, there are number of datasets, but all of them is not displayed(some have no value in specific time) at the same time ; some of them displayed on Monday and some of them on Tuesday, and so on...

How can I make a bar chart in this case?

Thank you.
bar.png

  Re: Discrete distributed dataset bar chart
Posted by Steve Mallin on Aug-31-2012 23:12
Looks like you should do this on the query side...

select baselinetable.ip, baselinetable.theday, ISNULL(megsused, "0") dataused FROM
(select distinct dt1.IPADDRESS ip from DATATABLE dt1
FULL OUTER JOIN
SELECT distinct dt2.DATADAY theday from DATATABLE dt2
WHERE dt2.DATADAY > GETDATE()-7) baselinetable
LEFT OUTER JOIN
select dt3.DATAAMT megsused from DATATABLE dt3
WHERE
baselinetable.ip = dt3.IPADDRESS AND
baselinetable.theday = dt3.DATADAY

might have to fix some syntax... just typing off the top of my head, but the algorithm there
should get you what you need.

  Re: Discrete distributed dataset bar chart
Posted by Peter Kwan on Sep-01-2012 05:21
Hi jettaime,

If you have a data series, and it has no value in some days, just put Chart::NoValue or 0 for that day.

So for '172.16.1.102', you may use { 999, 456, Chart::NoValue, .... }.

Hope this can help.

Regards
Peter Kwan