web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Computed Column as dimension attribute in OLAP Cubes

(0) ShareShare
ReportReport
Posted on by 2,710

Hello Everyone,

I am working on a BI project wherein, I need to split measures into buckets based on line amount.

E.g.

Bucket 1: Line Amt from 0 - 500

Bucket 2: Line Amt from 501 - 5000

Bucket 3: Line Amt from 5001 - 50000

Bucket 4: Line Amt from 50001 & Above

To achieve this, I added a computed column in view, which correctly determines the bucket.

Now, when I run SQL Analysis Services wizard to update the cube, it is not adding the Bucket column to Dimension Attributes. I have setup appropriate properties on the field in Perspective, but still am unable add the column as an attribute.

Field properties in Perspective:

AnalysisUsage=Attribute

AnalysisLabel=(at the rate)TMP112 [i.e. Amount Bucket - this is label from our custom label file]

Could anybody point what I am missing here?

Thanks & Regards,

Michael Brown

*This post is locked for comments

I have the same question (0)
  • Guy Terry Profile Picture
    28,924 Moderator on at

    Hi Michael,

    What cube are we talking about? And which View did you add the new field to?

  • MBrown1185 Profile Picture
    2,710 on at

    Hello Terry,

    Thanks for the reply.

    We have developed a new cube using a custom view. The view is based on CustSettlementTable and I am trying to put buckets based on Settlement Amount. The buckets appear perfectly if I open the view using table browser. However,  when I run SQL analysis services wizard, this column is not picked up as an attribute. The view has a joined table CustTrans. If I drag any of BaseEnum fields (like TransType) into the view, those fields are added as an attribute by wizard.

    Thanks & Regards,

    Michael Brown

  • Suggested answer
    Guy Terry Profile Picture
    28,924 Moderator on at

    I think the problem may be because the field is a Computed Column. CustTrans and TransType is a good example to explain my logic. First, some background.

    In BI speak, CustTrans is a "Fact Table"

    technet.microsoft.com/.../aa905984

    It contains some fields which are Measures and some fields which related to Dimensions.

    Each Dimension also needs a Dimension Table

    technet.microsoft.com/.../aa905979

    Switching to your example, in the Perspective, the 'CustCube' contains the CustTrans table, which contains the field TransType. TransType is a Dimension field. In the real CustTrans table, TransType is an Enum. An Enum field contains values which are linked (via a label) to a Description. This Enum and Description needs to form the basis of the TransType Dimension Table in the Cube.

    How is that represented in the Analysis Services database?

    Well, there is a Data Source View for CustTrans, which contains the TransType field. BUT, there is also a relationship to another View called CUSTTRANS_DIM:

    This View does not exist in the AX database, but is in fact based on a Table called SRSANALYSISENUMS (WHERE ENUMNAME = 'LedgerTransType'). From here, the Cube can get the TransType description (in many languages!). So CUSTTRANS_DIM is the Dimension Table.

    A similar thing happens for Dimensions which are not Enums. For example, Method of Payment is also on the CustTrans table. Method of Payment is a Dimension Field. In the Data Source View, there is a relationship to a View based on the table CUSTPAYMMODETABLE, which gives the Cube the Name of the Method of Payment. CUSTPAYMMODETABLE is the Dimension Table.

    In the case of Enums, the BI Wizard knows to use the SRSANALYSISENUMS table to create a Dimension Table. To create a Dimension Table for non-Enums, like Method of Payment, I assume the Relationship to the CUSTPAYMMODETABLE on the CustTrans table is used.

    With your Computed Column, there is no way for the BI Wizard to create a Dimension Table, since there is nothing behind it.

  • MBrown1185 Profile Picture
    2,710 on at

    Hello Terry,

    I'm sorry, I haven't been able to work on this today due to some urgent issues at hand. I'll get back to you tomorrow.

    Thanks a tonne for the detailed response!!

    Thanks & Regards ,

    Michael Brown

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans