Groups | Blog | Home
all groups > sql server misc > february 2004 >

sql server misc : Design Question: Calculated Field


imani_technology_spam NO[at]SPAM yahoo.com
2/3/2004 7:38:55 AM
I'm trying to create an OLAP system using SQL Server 2000 Analysis
Services (AS). I want the AS cube to be based on a database with a
star schema.

I have a field called Ratio. The initial ratio value is based upon
this formula: (CurrentTimePeriodAmount -
PreviousTimePeriodAmount)/PreviousTimePeriodAmount. However, that
initial ratio can be manually overridden and replaced. Then the ratio
is used to calculate future Amounts.

Should I place that calculated Ratio field in the "source" database
toddack NO[at]SPAM hotmail.com
2/3/2004 2:12:00 PM
What you may want to consider instead of creating a new field in the
physical table, is to use a view with the calculation there. I am a
huge advocate of using views for fact tables for the reason you are
talking about below.

The problem is if the ratio is going to be replaced/overridden you
need to ask yourself do you need to create a new record for this
ration value so you can track the changes over time. Are these changes
going to be adhoc, if so does your front-end tool allow for this type
of What If Functionality. Things to ask yourself.

HTH
-todd

[quoted text, click to view]
imani_technology_spam NO[at]SPAM yahoo.com
2/4/2004 8:25:51 AM
I want to be able to display an initial, calculated ratio. I also
want a seperate field for the user to type in a ratio. How could that
be implemented? Also, I'm considering using SQL Server Analysis
Services with some kind of MS Excel 2000 front end.

[quoted text, click to view]
AddThis Social Bookmark Button