467,075 Members | 962 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,075 developers. It's quick & easy.

Compare this year vs. previous year data in one graph (date vs. quantity)

I want to create a graph (automatically in a report) which compares
the current year's values to the previous years by plotting two lines
on one chart.

I have one table which has the fields: Date and DeckDefects (which
is a number)

I would like the X axis to show months and the Y axis to show # of
DeckDefects
This should be real easy, but I can't find anything about it.

Thanks

Sep 25 '07 #1
  • viewed: 4335
Share:
1 Reply
Craig, I assume that this year's values and last year's values are all in
the one table (which is the right design.) Since you want 2 different
results for two different periods from the same table, use a subquery to get
last year's results and match them to this one.

If subqueries are new, see:
Subquery basics: Year to date
at:
http://allenbrowne.com/subquery-01.html#YTD
The article discusses what subqueries are, and demonstrates how to make a
year-to-date query. You can do a period-compared-to-last-year in the same
way.

Once you have the query, you can use it as the source for one of the chart
types that handles multiple domains.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

<cr*****@craigfr.comwrote in message
news:11**********************@r29g2000hsg.googlegr oups.com...
>I want to create a graph (automatically in a report) which compares
the current year's values to the previous years by plotting two lines
on one chart.

I have one table which has the fields: Date and DeckDefects (which
is a number)

I would like the X axis to show months and the Y axis to show # of
DeckDefects

This should be real easy, but I can't find anything about it.

Thanks
Sep 26 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

9 posts views Thread by Rich | last post: by
3 posts views Thread by jannoergaard@hotmail.com | last post: by
12 posts views Thread by Assimalyst | last post: by
25 posts views Thread by Brian | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.