Crosstab Query (1 Viewer)

janeyd

Registered User.
Local time
Today, 19:55
Joined
Jun 24, 2011
Messages
27
Hi

I have a crosstab query with one row heading and lots of column headings that show over several pages. Is there a way of having the row heading appear at the start of every page?

Thank you
 

Ranman256

Well-known member
Local time
Today, 14:55
Joined
Apr 9, 2015
Messages
4,339
that would be a report and that is even trickier.
youd need to make a 'report' table. This table would have every possible field as a column heading.
then make the report with headings on every page.

dump the crosstab into the 'report tbl'
run the report.
 

isladogs

MVP / VIP
Local time
Today, 19:55
Joined
Jan 14, 2017
Messages
18,209
You mean something like this?



Here is the design so you can see what I've put where



NOTE: There are in fact 60 column headers but placed one on top of the other in the design
When the report is opened inprint preview, the number of columns is calculated & the column headers placed accordingly
Any empty columns are not displayed (i.e. if there are less than 60 columns worth of data)

If you need to do so, column headings can be specified in one of 2 ways:
a) using fixed headings specified in the property sheet - e.g. "Jan", "Feb" etc
b) using dynamic crosstab report code where the columns are adapted to fit the current data
 

Attachments

  • Capture.jpg
    Capture.jpg
    104.5 KB · Views: 230
  • CaptureDesign.PNG
    CaptureDesign.PNG
    42.7 KB · Views: 205

isladogs

MVP / VIP
Local time
Today, 19:55
Joined
Jan 14, 2017
Messages
18,209
Just to add that my report is based on the crosstab query.
It isn't necessary or indeed desirable to save it to a table if you get the column headers in one of the ways I've described.
 

Users who are viewing this thread

Top Bottom