MS Chart and displaying Monthly Sales Figures

I'm pulling sales data from sql server 2005 express db, and i need to show each salesperson's monthly figures in a chart.  The table data is as such...(just an example)

Salesperson   |   OrderDate   |   OrderAmount
Jack                     12/1/2010         100
Jack                     13/1/2010          50
Jane                     1/2/2010            50
Jill                          1/3/2010           50
Jack                       5/3/2010           100

I created a view in the database to sum up the data and got this:
Salesperson  |  Month  |  Year  |  TotalOrder
Jack                      1        2010           150
Jack                      3        2010           100
Jane                      2        2010             50
Jill                          3        2010           50

The problem with this is that when i assign the x values and y values in the chart control, it will only take the available values in the query.  What i wanted to show in the graph is that, for example, Jack sold 150 in Jan-2010, 0 in Feb-2010, and then 100 in Mar-2010.

Is there some way i can get around this? Maybe manually create the x-values, and then map the y-values to the manual x-values?

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

I supose you're grouping your query by orderDate month, you may try to use an IIF statement to create an empty values registry in the months where there is no records
GCCTECHIEAuthor Commented:
Hi Bardo,
did you mean in the query or in the chart settings?
In the query, try something like:

IIF(Not IsNull(SUM(OrderAmount)),SUM(OrderAmount),0)

The idea es to get a record for every possible month value, and if there is no record, force to a 0 record... I'm not sure that this is going to work, but it could be a possibility.

Maybe you can force a resultset with the 12 months...

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

GCCTECHIEAuthor Commented:
hi bardo,

sorry i took so long. i have been trying, to no success.
Did you get a query with the 12 months for every salesperson?
GCCTECHIEAuthor Commented:

I ended up with four queries to get the end result, one on top of another...but i managed to get it to work.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Query Syntax

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.