none
Dimension with parent key+primary key+Surrogate key RRS feed

  • Question

  • Hi, PLZ help ...........

    in my SSAS Project I need to handle historical changes (Type 6 - SCD)

    VCode : surrogate key

    Place VCode : Bussiness key

    I want to have parent-Child relationship btw current/Historical ParentVCode and PlaceVCode => PlaceVCode should be KEY

    from other view surrogate key(VCode) sholud be KEY , so by this i can connect Dimension to Fact => VCode Should be KEY

    plz help me to solve this problem?? which one should be key?

    * I dont use SSIS and I manage historical changes by Stored Procedures Written by T-Sql

    My Dimension Fields are :

           [VCode]
          ,[PlaceVCode]
          ,[CurrentPlaceName]
          ,[HistoricalPlaceName]
          ,[CurrentParentVCode]
          ,[HistoricalParentVCode]
          ,[LVL]
          ,[CenterZone]
          ,[Dimensions]
          ,[EffectiveDate]
          ,[ExpirationDate]
          ,[Current]


    Tuesday, February 28, 2017 8:49 AM

All replies

  • Hi samiraab,

    Thanks for your question.

    If i understand correctly,surrogate key VCode should be primary key.

    A surrogate key is any column or set of columns that can be declared as the primary key instead of a "real" or natural key. Sometimes there can be several natural keys that could be declared as the primary key, and these are all called candidate keys. So a surrogate is a candidate key. A table could actually have more than one surrogate key, although this would be unusual. The most common type of surrogate key is an incrementing integer, such as an identity column in SQL Server.

    Best Regards
    Willson Yuan
    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Wednesday, March 1, 2017 1:09 AM
    Moderator
  • hi 

    I m very Grateful for your response,

    With Consideration that,  one attribute Could be set as Key Attribute in dimension Structure,

     what is your suggestion to solve the problem ?

    Wednesday, March 1, 2017 12:06 PM
  • Hi samiraab,

    Thanks for your response.

    In this scenario,please refer to Type 6 Slowly Changing Dimensions Example.

    Best Regards
    Willson Yuan
    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Thursday, March 2, 2017 3:04 AM
    Moderator