Cross Tab Totaling

G

Guest

I have a query that totals the revenue by weeks, how can i then have an
overall total?

TRANSFORM Sum([7 2005 and 2006 Sales data by week 1-18].[TurGN-NT1]) AS
[SumOfTurGN-NT1]
SELECT [7 2005 and 2006 Sales data by week 1-18].Customer
FROM [7 2005 and 2006 Sales data by week 1-18] INNER JOIN [Week to Date
conversion table] ON [7 2005 and 2006 Sales data by week 1-18].Week = [Week
to Date conversion table].Week
GROUP BY [7 2005 and 2006 Sales data by week 1-18].Customer
PIVOT [Week to Date conversion table].Date;
 
G

Guest

Try:

TRANSFORM Sum([7 2005 and 2006 Sales data by week 1-18].[TurGN-NT1]) AS
[SumOfTurGN-NT1]
SELECT [7 2005 and 2006 Sales data by week 1-18].Customer,
Sum([7 2005 and 2006 Sales data by week 1-18].[TurGN-NT1]) AS OverallTotal
FROM [7 2005 and 2006 Sales data by week 1-18] INNER JOIN [Week to Date
conversion table] ON [7 2005 and 2006 Sales data by week 1-18].Week = [Week
to Date conversion table].Week
GROUP BY [7 2005 and 2006 Sales data by week 1-18].Customer
PIVOT [Week to Date conversion table].Date;

Ken Sheridan
Stafford, England
 

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

Top