Continuous time link to discrete time dimension

Post Reply
WayneBo
Posts: 20
Joined: Mon Sep 16, 2019 12:17 am
OLAP Product: TM1 Planning Analytics
Version: 2.0
Excel Version: 2019

Continuous time link to discrete time dimension

Post by WayneBo »

Hi All:

I have a question regarding to the 2 different types of time dimension (continuous vs discrete)

I have an occupancy cube using continuous time dimension on daily level to record the daily occupancy number.
Continuous time dimension has 4 levels, Year-Month-Week-Day.

Then, I have budget cube using the discrete time dimension ( have year dimension, month dimension ).
In this budget cube, I have budgeted occupancy on monthly level.

Now, I want to compare the actual vs budget occupancy on a daily level.
I am able to do a rule in budget cube to calculate the daily budget number by divide the monthly budget number by the month days (Dim Month attributes).

But I don't know how do I transfer the calculated daily budget number ( which on month level in a discrete time in budget cube) to the daily occupancy cube ( which is using the continuous time on daily level) in the relevant (correct) month and year.

Could and TM1 expert kindly provide help.

Thank you
W
User avatar
orlando
Community Contributor
Posts: 167
Joined: Fri Aug 04, 2017 8:27 am
OLAP Product: TM1
Version: PAL 2.0.8
Excel Version: Office 365

Re: Continuous time link to discrete time dimension

Post by orlando »

WayneBo wrote: Fri Sep 27, 2019 1:33 am Hi All:


But I don't know how do I transfer the calculated daily budget number ( which on month level in a discrete time in budget cube) to the daily occupancy cube ( which is using the continuous time on daily level) in the relevant (correct) month and year.

Hi,

here is my very fast idea - early in the morning ;)

You need a "Month" Attribute on the day.

You then have a rule in your actuals cube, that reads the Month Attribute from the day in a DB rule to get the figures from the budget cube.

Could be somethink like that

['budget_Element_in_actual_cube'] = N: DB('budgetCube', Dim1, Dim2, ATTRS('DimWithDay', !DimWithDay, 'Month'), 'DailyBudget');

Best regards,

orlando
WayneBo
Posts: 20
Joined: Mon Sep 16, 2019 12:17 am
OLAP Product: TM1 Planning Analytics
Version: 2.0
Excel Version: 2019

Re: Continuous time link to discrete time dimension

Post by WayneBo »

Hi Orlando:

Thanks for your help.

I did small sample test, and it works.

But that bring me another question.

How do I mass edit my continuous time dimension attributes?
When I built the continuous time dimension, I didn't populate the Year and Month attributes, and this dimension been used in so many cubes already.

Is there a way that I can mass edit the attributes of a dimension after the dimension been created already?

Please kindly advise.

Thank you
W
User avatar
orlando
Community Contributor
Posts: 167
Joined: Fri Aug 04, 2017 8:27 am
OLAP Product: TM1
Version: PAL 2.0.8
Excel Version: Office 365

Re: Continuous time link to discrete time dimension

Post by orlando »

WayneBo wrote: Fri Sep 27, 2019 6:42 am Hi Orlando:


Is there a way that I can mass edit the attributes of a dimension after the dimension been created already?

How does you dimension look like? Could you post a screenshot?
User avatar
Steve Rowe
Site Admin
Posts: 2456
Joined: Wed May 14, 2008 4:25 pm
OLAP Product: TM1
Version: TM1 v6,v7,v8,v9,v10,v11+PAW
Excel Version: Nearly all of them

Re: Continuous time link to discrete time dimension

Post by Steve Rowe »

WayneBo wrote: Fri Sep 27, 2019 6:42 am
Is there a way that I can mass edit the attributes of a dimension after the dimension been created already?
Use a TI process to with the a level zero subset of the dimension as a datasource and write the attribute to the dimension
or
use the DBSA formula to write the value from Excel
Technical Director
www.infocat.co.uk
WayneBo
Posts: 20
Joined: Mon Sep 16, 2019 12:17 am
OLAP Product: TM1 Planning Analytics
Version: 2.0
Excel Version: 2019

Re: Continuous time link to discrete time dimension

Post by WayneBo »

Hi Orlando:

Thanks for your help.

The below is my dimension screen shot.

As you can see, I am at the moment, manually adding the year number and month number to the 2 newly add attributes of the dimension on day level.

Just wandering , if there is a fast way / automatic way to do this process, maybe by using rules or formulas?

Thanks a lot.
W

Image
TimeDimension.png
TimeDimension.png (217.62 KiB) Viewed 6324 times
User avatar
gtonkin
MVP
Posts: 1261
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: Latest and greatest
Excel Version: Office 365 64-bit
Location: JHB, South Africa
Contact:

Re: Continuous time link to discrete time dimension

Post by gtonkin »

You could add an alias to your existing Month dimension to store 01, 02 etc. for Jan, Feb and so on.

On your Time dimension add a new attribute for Month and a rule to derive the Month (Jan, Feb...) by parsing the month from the element (subst first 2 characters) against your month dimension.

You may want to also create a Year element and populate it by rule using a subst on characters 7-10

You will need to consider rules for your leaf levels as well as each other level in the various hierarchies.

Hope this helps.
BR, George.

Learn something new: MDX Views
User avatar
orlando
Community Contributor
Posts: 167
Joined: Fri Aug 04, 2017 8:27 am
OLAP Product: TM1
Version: PAL 2.0.8
Excel Version: Office 365

Re: Continuous time link to discrete time dimension

Post by orlando »

WayneBo wrote: Fri Sep 27, 2019 12:33 pm Hi Orlando:

Just wandering , if there is a fast way / automatic way to do this process, maybe by using rules or formulas?

ImageTimeDimension.png
Hi,

yep - there is.
Rule or TI.

If you're using a Rule - you don't have to worry about new elements

somethink like that should work - https://exploringtm1.com/subst-tm1-function-use-syntax/

Year = SUBST(!DimensionWithDay, 7, 4);

for the day u the same

if you don't like a rule you can use SUSBT in an TI.

best regards and have a nice weekend
orlando
WayneBo
Posts: 20
Joined: Mon Sep 16, 2019 12:17 am
OLAP Product: TM1 Planning Analytics
Version: 2.0
Excel Version: 2019

Re: Continuous time link to discrete time dimension

Post by WayneBo »

Thanks Orlando, thats help a lot.

W
Post Reply