By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,851 Members | 1,308 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,851 IT Pros & Developers. It's quick & easy.

How to alter the field ordinal position after the table has been defined?

P: 1
I have a table created based in a crosstab query, automatically the table was created with the Totals Column in the second column, how I can alter the ordinal position of column Totals using VBA?

This comes due that after I show the created table in a web page and the Total columns is showed in second place, additionally this table is dynamic, the rest of the columns could change in name and number of fields, the unique constant is the column Total and I need it in the last column at the right side.
Nov 7 '13 #1
Share this Question
Share on Google+
3 Replies

Expert 100+
P: 1,221
Perhaps you could use
Expand|Select|Wrap|Line Numbers
  1. Select *, Totals as TotalAmount from tablename
Of course that would give you the totals column twice but you don't have to do anything with the first.

Nov 8 '13 #2

Expert Mod 15k+
P: 31,308
Go into the design of the table and drag the fields you want to reposition.

You can also drag the fields around when the data is displayed, but that doesn't move the field in the design itself, just where it displays.
Nov 9 '13 #3

Expert Mod 5K+
P: 5,332
You've stated that the CTQ is dynamic, in which case, you will need to explain how you are creating the query.
You'll should also find AB's tutorial on CTQ to be helpful: Allen Browne: Crosstab query techniques
Nov 12 '13 #4

Post your reply

Sign in to post your reply or Sign up for a free account.