Help using crosstab

fbm2themex

Registered User.
Local time
Today, 00:49
Joined
Aug 21, 2007
Messages
12
Im trying to use crosstab to help me out count how many pages are within a document...
for example
in my "break" field. there are records that contain D's(d=document), and blank records(blanks=pages)...im trying to use crosstab to help me count how many are within each document....but for some reason, its not coming out right...can anyone help me?

i keep getting this error when i try running my crosstab query...
"Too many crosstab column headers(21521)"
is it possible since i have so many records...i cant perform this task??

heres a cpy of my db
 

Attachments

Last edited:
One problem you're facing is that a crosstab query can only contain so many column headers (255 is max I think). If you switch your row header and column header you should be able to get your results to show. Secondly, your data table contains no values in the total column so there is nothing to display in your crosstab value columns.
 
One problem you're facing is that a crosstab query can only contain so many column headers (255 is max I think). If you switch your row header and column header you should be able to get your results to show. Secondly, your data table contains no values in the total column so there is nothing to display in your crosstab value columns.

thats what im trying to figure out, the total values of each D. so, i cant use cross tab to calculate the amount?
 
Your question is confusing since your data table doesn't appear to contain any field that can be used to aggregate records. Your ID field contains a unique value for each record (row). How is the query supposed to know which of the D's or nulls belong with each other? That said, it looks as if the last 6 characters in the ID field are just a sequential number tacked onto the end of some base identifier. So, if the preceding letters/numbers identify which records truly belong together then you can use left([ID],Len([ID])-6) to create your row heading field.

From there, see the attached db. It should show you how to use a crosstab to COUNT D's, or to count Nulls.
 

Attachments

Your question is confusing since your data table doesn't appear to contain any field that can be used to aggregate records. Your ID field contains a unique value for each record (row). How is the query supposed to know which of the D's or nulls belong with each other? That said, it looks as if the last 6 characters in the ID field are just a sequential number tacked onto the end of some base identifier. So, if the preceding letters/numbers identify which records truly belong together then you can use left([ID],Len([ID])-6) to create your row heading field.

From there, see the attached db. It should show you how to use a crosstab to COUNT D's, or to count Nulls.

thanks, i was way off then.
thank you so much
 

Users who are viewing this thread

Back
Top Bottom