Create SQL Results table

I am trying to add some new functionality to an existing database, and I am not sure how to proceed.  I have an Access front end to a SQL 2005 database.  I am attempting to add the abilitiy to run a series of calculations on an existing table and then create a results table that is named something like tbCalculations01_09262013, tbCalculations02_09262013, tbCalculations03_09272013, etc.  

The table will have the following schema:
CREATE TABLE [dbo].[tbCalculations01_09262013](
      [OBJECTID] [int] IDENTITY(1,1) NOT NULL,
      [SDEID] [nvarchar](18) NULL,
      [CONDCAT01] [int] NULL,
      [CONDCAT02] [int] NULL,
      [CONDCAT03] [int] NULL,
      [CONDCAT04] [int] NULL,
      [CONDCAT05] [int] NULL,
      [CONDCAT06] [int] NULL,
      [CONDCAT07] [int] NULL,
      [CONDCAT08] [int] NULL,
      [CONDCAT09] [int] NULL,
      [CONDCAT10] [int] NULL,
      [CALCBY] [nvarchar](20) NULL,
      [CALCDATE] [datetime] NULL,
      [VALIDFROM] [datetime] NULL,
      [VALIDTO] [datetime] NULL,

I'm thinking that I should create the table, append the SDEID values and then perform the calculations.  Ideally, I would like for the user to be able to be able to execute this from the Access front end.  

Is this possible?
Aaron GreeneProgrammerAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

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.

Jim HornMicrosoft SQL Server Data DudeCommented:
That's gonna be a wompload of moving parts if the idea is to on-the-fly create a SQL table, link it to Access, and then have the Access UI manipulate it.

I believe a better idea would be to create your tblCalculations without the suffix.
Add a column for the MMDDYYYY of the calculations.
maybe add another column for the user.

Then, populate that table based on the day and user.
Then, one Access linked table will be able to handle it without any changes, and same goes with the Access queries and forms, other than for queries you'd have to WHERE on the date and maybe user.

Also, what kind of calculations are we talking about?  SQL has the ability to create a calculated column based on an expression involving other columns, so that may be an option for you.

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
Aaron GreeneProgrammerAuthor Commented:
That is a good idea, and will probably make reporting the data a simpler process.  The calculations are pretty simple.  For example, I have a function that returns a rating of the asset based on its age.  For example an asset that is 50 years old will get a rating of 10.  I have views that show these results, so I really need to be able to append a view to the table.
You don't actually need to save the calculated values.  In fact calculating them as you go is far better practice because they will always be current.  Unless the calculations involve complex joins and functions, there is no real speed hit to do them in the query.  I do prefer to do the calculations in the query rather than the report whenever possible because that leaves open the option to sort and group on the calculated value.  But, simple summing should always be done in the report.
Aaron GreeneProgrammerAuthor Commented:
Both answers were helpful.
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 SQL Server

From novice to tech pro — start learning today.