locked
Calculated column - formula to include column from related table RRS feed

  • Question

  • In SSAS, I have 2 tables that are related:

    Incidents (many) : (1) Dates

    In my incidents table I am trying to create a calculated column that retrieves a column from the Dates table as part of a calculation, but it won't recognise any columns from any related table, even if I just create a simple equals formula:

    ='Dates'[ColumnName]

    I'm working on a tabular model in SSAS that will be used in a Power BI report.

    Tuesday, January 29, 2019 11:40 AM

Answers

  • Hi PetyrBaelish

    I believe that you should use the Related function. Because when you are creating calculated column you operate in row context. Row context does not automatically propagate through relationships like filter context does.

    HTH

    Ivan 


    Ivan Roguljić

    • Proposed as answer by Darren GosbellMVP Wednesday, January 30, 2019 1:06 AM
    • Marked as answer by PetyrBaelish Wednesday, January 30, 2019 11:06 AM
    Tuesday, January 29, 2019 11:07 PM

All replies

  • Hi PetyrBaelish

    I believe that you should use the Related function. Because when you are creating calculated column you operate in row context. Row context does not automatically propagate through relationships like filter context does.

    HTH

    Ivan 


    Ivan Roguljić

    • Proposed as answer by Darren GosbellMVP Wednesday, January 30, 2019 1:06 AM
    • Marked as answer by PetyrBaelish Wednesday, January 30, 2019 11:06 AM
    Tuesday, January 29, 2019 11:07 PM
  • Thanks - the RELATED function completely slipped my mind
    Wednesday, January 30, 2019 11:06 AM