Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
|
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 30th, 2004, 04:10 PM
Registered User
 
Join Date: Oct 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Please help with query properties

I have a crosstab query (qryRollAvg)that I need to modify the ColumnHeading property to equal strHeader (actaully the value of variable strHeader) using ADO. Any help would be greatly appreciated.

Tom

 
Old April 1st, 2004, 12:22 PM
Registered User
 
Join Date: Mar 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You can change the Column Headings to what every you want in the PIVOT part of the SQL statement. However, whatever have in Column Headings is what the query looks for when returning the data. If the headings you enter do not match the values in the PIVOT column the query will not return anything. Changing the column headings really only serves to reorder the results or limit what is returned by the query.

In any case, here is the syntax of the PIVOT part of a CrossTab with the Headings entered

PIVOT tblCrossTabTest.MonthYear In ("Jan-2000","Feb-2000","Mar-2000")

Hope this is clear. It is kind of hard to explain.





Doogie's Mom
Look at the World with the Eyes of a Child





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to set properties of query in Access VBA LittleCity Access VBA 2 September 27th, 2006 08:42 AM
Properties Explorer Bradml VB How-To 2 May 3rd, 2006 06:05 PM
properties aadz5 C# 3 December 29th, 2003 11:38 AM
Properties robert_83 .NET Web Services 0 July 30th, 2003 07:27 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.