Hi all,
New member.
I almost don't know how to ask this but here goes I have tried a search with no result.
I have a table (curmonthsale) with fields:
pnum
report date
sales amount.
I have linked this table with another table (sale) with fields:
pnum (the linked field)
jan
feb
mar
apr
may
jun
jul
aug
sep
oct
nov
dec
I need to do an update query that updates the fields in (sale) according to multiple criteria. Like:
when (curmonthsale) linked pnum matching pnum in (sale) and report date = "2016/01" updates the jan field to sales amount from the (curmonthsale)
I can do this query for one update at a time or in an IIF statement (7 limit), but i would like to do all the months in one update query.
In other words do all the updates in one query. if report date (curmonthsale)= 2016/01 than update Jan (Sale) with sales amount plus if report date (curmonthsale)= 2016/02 than update Feb (Sale) with sales amount, plus all the other months.
I don't know VBA at all, but can do some limited SQL. I do most my work in design view but have enough (barely) knowledge to do and edit the SQL view.
Hopefully I have worded this question properly and not too dumb.
Thank you for your help,
Doug