Part Forecast Table

Hello Experts,
I have a table in Access 2003 database.  I have values in the year 2015 that I want to copy into 2016.  Can someone write me a SQL statement that can accomplish this.  Thanks!
PartForecast05292015.xls
Steve EckermanSystems AdministratorAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Steve EckermanSystems AdministratorAuthor Commented:
Please see the attached table.  Thanks!
0
PatHartmanCommented:
Append queryOpen the QBE to create a new query.
Select the forecast table.
Select all the columns (don't use the *)
Change the query type to Append.
Choose the forecast table to append to.  Notice that all the Append To boxes fill.
Now, we have to make two changes:
For the FiscalYear column, remove the append to value and add criteria to select the year you want to copy.
Add a final column using "2016" as the Field.  Access will name it Expr1 and choose FiscalYear in the append to.

So, this will select the rows with FiscalYear = 2015 and append the rows, changing the FiscalYear value to 2016.
0
Steve EckermanSystems AdministratorAuthor Commented:
I was not able to do this correctly.  Could you send me the SQL syntax that would accomplish this?  Thanks!
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

PatHartmanCommented:
What error are you getting?  Please post what you have done and we'll look at it.
0
Steve EckermanSystems AdministratorAuthor Commented:
I got it to work but it put duplicates in my table for 2016.  Do you know of something that I can run to get rid of the duplicates in 2016?  Please advise.  Thanks!
0
PatHartmanCommented:
Delete all the 2016 records.
Open the table in design view and add a proper unique index that will prevent duplicates.
Rerun the append query.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Steve EckermanSystems AdministratorAuthor Commented:
Great answer!  Thanks!
0
PatHartmanCommented:
You're welcome.  And a final bit of advice - make a copy of a table before running an untested batch update.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.