Query on Column Heading

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have an Access table containing budget data by month. Each row is an
account, and each column is a month. I'm looking to create a Query that will
return the data for a specified month or a range of months.
 
putting data into field names breaks the rules of table normalization.
suggest you correct your table design. such as:

tblAccounts
AcctID (primary key)
AccountName
other fields that describe the account

tblAcctBudgets
AcctID (foreign key from tblAccounts)
BudgetMonth
BudgetYear
BudgetAmount
(primary key can be three fields: AcctID, BudgetMonth, BudgetYear. or you
can add an additional field such as an autonumber, to serve as the primary
key.)

you can query tblAcctBudgets to return any subgroup of data that you need.

hth
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top