Selasa, 16 Februari 2016

RE: [MS_AccessPros] Crosstab as data source for subsequent queries


If the column headings are date intervals such as week, month, quarter, or year I will use a reference week, month, quarter, or year to generate headings like "Wk1", "Wk2", or "Mth0", "Mth1".
I have also pushed all possible column headings into a renaming table with the value and an alias like "A", "B", "C", etc. I join my original table with the renaming table so my column headings become "A", "B", "C", etc.
In both of these solutions I enter all possible column headings into the Column Headings property.
Duane Hookom, MVP
MS Access

Date: Tue, 16 Feb 2016 11:40:54 -0500
Subject: [MS_AccessPros] Crosstab as data source for subsequent queries

I find myself needing to work with crosstabs lately and needing to use the output of a crosstab as the data source for another query. Crosstab field names are dynamic. By that I mean that the field names in the query result depend on the data being transformed. So the field list will have differing numbers of fields from run to run. I am currently managing the output by using VBA to generate TRANSFORM SQL at runtime and then replace the SQL in a querydef. This provides me with the source for further downstream processing that is responsive to current data and user request.


Can anyone share their insight into using crosstabs especially as the source for further querying?







Posted by: Duane Hookom <>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (6)



Tidak ada komentar:

Posting Komentar