Blank Columns in Access Query

Crasybebe

New Member
Joined
Oct 24, 2007
Messages
30
Does anyone know if there is a way to program a query to produce a report with a blank column for every other row?

Example
Cross tab Query:

TRANSFORM Val(Nz(Sum([Openings by Country].[OPEN POS]),0)) AS [SumOfOPEN POS]
SELECT [Openings by Country].COUNTRY, [Openings by Country].Region
FROM [Openings by Country]
GROUP BY [Openings by Country].COUNTRY, [Openings by Country].Region
ORDER BY [Openings by Country].Region
PIVOT [Openings by Country].LOB;

I would like the report to display a blank column in between each LOB.

Any ideas are much appreciated.

Thanks!
 

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
You can define the headers in the crosstab's properties.

Right-click in the grid, in the Column Headings field (LOB). In the Column Headings property enter the field names -- "A","A_Blank","B","B_Blank"... etc
Where A, B, etc are the LOBs and the others are the desired blank fields.

Disadvantage: If the LOBs change you will need to adjust the headers because this approach hard-wires them, and values not listed will be ignored.

Denis
 
Upvote 0

Forum statistics

Threads
1,224,609
Messages
6,179,874
Members
452,949
Latest member
Dupuhini

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top