הצטרפו לקבוצות שלנו לקבלת עדכונים מרוכזים פעם בשבוע:

ווטסאפ:
http://wa.dwh.co.il
טלגרם:
http://telegram.dwh.co.il

YTD

More
16 years 1 month ago #5369 by Avner_ni
YTD was created by Avner_ni
שלום רב.


מסד הנתונים SQL SEVER 2008. SSAS.

ברצוני לדעת האם יש ב-OLAP אפשרות לחשב YTD - כלומר: ערך של Measure מתחילת השנה עד התאריך הנוכחי (Runing Sum(.

האם יש אפשרות מובנית לזה, ואם לא - מה ה-MDX שאני צריך לרשום.

בתודה מראש
אבנר

Please התחברות to join the conversation.

More
16 years 1 month ago #5390 by BarakYL
Replied by BarakYL on topic תגובה:YTD
אם יש לך מימד תאריך הירארכי, אז אתה יכול לקחת את הערך של המדד בשנה הנוכחית. משהו כמו [dates.year.[2010
אם אין לך מימד תאריך הירארכי, אז תעשה

Please התחברות to join the conversation.

More
16 years 1 month ago #5391 by eldad
Replied by eldad on topic תגובה: YTD
this example shows how to use YTD:
SELECT
{} ON COLUMNS,
YTD([Date].[Calendar].[Month].[July 2003]) ON ROWS
FROM
[Adventure Works]

the only thing missing is what to do with the set that returns from the query.

this exaple show how to use YTD and Sum:

WITH
MEMBER [Measures].[YTDSum] AS
SUM(YTD([Date].[Calendar].[Month].[July 2003])
, [Measures].[Customer Count])
SELECT
{[Measures].[YTDSum]} ON ROWS
FROM
[Adventure Works]

Please התחברות to join the conversation.

Moderators: eldad
Time to create page: 0.268 seconds