Crosstab Report

  • Thread starter Thread starter David Chavez
  • Start date Start date
D

David Chavez

I have a crosstab report and I want the report to display
a fixed number of columns. My problem is if these column
have no data then I get an error. This is the query I
have created.

TRANSFORM Val(Nz(Sum([PDAEX]),0)) AS SumOfPDAEXPYTD
SELECT DirectLAE2.CompanyName, DirectLAE2.State,
Year.Year2, Sum(DirectLAE2.PDAEX) AS [Total Of PDAEXPYTD]
FROM DirectLAE2 LEFT JOIN [Year] ON
DirectLAE2.AccYr1=Year.Year1
GROUP BY DirectLAE2.CompanyName, DirectLAE2.State,
Year.Year2
PIVOT DirectLAE2.ANSTMTLINE;
 
Fred,
Is there a way to have fixed rows too?
Even if the data does not exist.
Thanks
David Chavez
-----Original Message-----
You could set the number of column you want in "Query
properties","column Headings" write your coulumn header
comma separated. EX.: "a","B","C",....,"Z" then if there
is no data it will print.
 
Thanks Fred your comment for the Heading WORKED!

David
-----Original Message-----
You could set the number of column you want in "Query
properties","column Headings" write your coulumn header
comma separated. EX.: "a","B","C",....,"Z" then if there
is no data it will print.
 
Back
Top