cross tabg query

J

JRS

My cross tab query results are not listing the months in chronological order.
Also I wold like a total for each month of all types, I have a total by type
eg.
Jan Feb Mar Total
apple 2 3 7 12
orange 1 1 1 3
pear 2 2 2 6
Total 5 6 10 21

TRANSFORM Sum(Gold.[CountOfLog Date]) AS [SumOfCountOfLog Date]
SELECT Gold.Type, Sum(Gold.[CountOfLog Date]) AS [Total Of CountOfLog Date]
FROM Gold
GROUP BY Gold.Type
PIVOT Gold.MonthAndYear;

thank you
 
A

ANDY-N via AccessMonster.com

In the column heading properties add "jan", "feb", "mar", "apr", "may", "jun",
"july","aug","sept","oct","nov","dec"
My cross tab query results are not listing the months in chronological order.
Also I wold like a total for each month of all types, I have a total by type
eg.
Jan Feb Mar Total
apple 2 3 7 12
orange 1 1 1 3
pear 2 2 2 6
Total 5 6 10 21

TRANSFORM Sum(Gold.[CountOfLog Date]) AS [SumOfCountOfLog Date]
SELECT Gold.Type, Sum(Gold.[CountOfLog Date]) AS [Total Of CountOfLog Date]
FROM Gold
GROUP BY Gold.Type
PIVOT Gold.MonthAndYear;

thank you
 
A

ANDY-N via AccessMonster.com

In the MONTH column heading properties add "jan", "feb", "mar", "apr", "may",
"jun", "july","aug","sept","oct","nov","dec"
My cross tab query results are not listing the months in chronological order.
Also I wold like a total for each month of all types, I have a total by type
eg.
Jan Feb Mar Total
apple 2 3 7 12
orange 1 1 1 3
pear 2 2 2 6
Total 5 6 10 21

TRANSFORM Sum(Gold.[CountOfLog Date]) AS [SumOfCountOfLog Date]
SELECT Gold.Type, Sum(Gold.[CountOfLog Date]) AS [Total Of CountOfLog Date]
FROM Gold
GROUP BY Gold.Type
PIVOT Gold.MonthAndYear;

thank you
 
J

JRS

is ther a way to get the total line? thanks

ANDY-N via AccessMonster.com said:
In the MONTH column heading properties add "jan", "feb", "mar", "apr", "may",
"jun", "july","aug","sept","oct","nov","dec"
My cross tab query results are not listing the months in chronological order.
Also I wold like a total for each month of all types, I have a total by type
eg.
Jan Feb Mar Total
apple 2 3 7 12
orange 1 1 1 3
pear 2 2 2 6
Total 5 6 10 21

TRANSFORM Sum(Gold.[CountOfLog Date]) AS [SumOfCountOfLog Date]
SELECT Gold.Type, Sum(Gold.[CountOfLog Date]) AS [Total Of CountOfLog Date]
FROM Gold
GROUP BY Gold.Type
PIVOT Gold.MonthAndYear;

thank you
 

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