Budget Comparison

K

Krish

I have created a table as follows:
SELECT dbo_Customer.AccountNumber, dbo_Customer.Company,
dbo_PUBLIC_SalesRep.Name, Format([Time],"mm/yyyy") AS [Date],
Sum(dbo_PUBLIC_TransactionEntry!Price*dbo_PUBLIC_TransactionEntry!Quantity)*
1.3 AS Budget2005 INTO 2005WholesaleSalesBudget
FROM dbo_Customer INNER JOIN ((dbo_PUBLIC_Transaction INNER JOIN
dbo_PUBLIC_TransactionEntry ON dbo_PUBLIC_Transaction.TransactionNumber =
dbo_PUBLIC_TransactionEntry.TransactionNumber) INNER JOIN
dbo_PUBLIC_SalesRep ON dbo_PUBLIC_TransactionEntry.SalesRepID =
dbo_PUBLIC_SalesRep.ID) ON dbo_Customer.SalesRepID = dbo_PUBLIC_SalesRep.ID
WHERE (((Format([Time],"yyyy"))=2004))
GROUP BY dbo_Customer.AccountNumber, dbo_Customer.Company,
dbo_PUBLIC_SalesRep.Name, Format([Time],"mm/yyyy"), dbo_Customer.SalesRepID
HAVING (((dbo_Customer.SalesRepID)=1 Or (dbo_Customer.SalesRepID)=4));
I want to use these figures to compare with 2005 Actual sales by Customers,
by month preferably as Crosstab query. If for reasons, a customer has no
activity in 2005, I would still need to see what was budgeted. On the
contrary, if a new customer is added, I want the query to show actulas
without budget.
How do I accomplish?
Thanks.
krish
 
M

[MVP] S.Clark

Look into the help file about Outer Joins. They will help in your
situation.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top