Duplicate key fodound when processing dimension

  • Hi,

    When i am processing the cube i got the error in one of the dimension.

    I have data like below.

    Companycode Documnet Status

    1 1 Start

    1 1 Stop

    2 1 start

    2 1 stop

    I created Surrogate key like this

    Doc_Surrogatkey Companycode Documnet Status

    1 1 1 Start

    1 1 1 Stop

    2 2 1 start

    2 2 1 stop

    i took distinct company code and document ,created one intermediate dimension and generated like below

    Surrogatekey Doc_Surrkey Document

    1 1 1

    2 2 1

    In fact table i used Intermediate table surrogate key. In SSAS Cube ,Dimension usage I added the dimension and creation referenced relation ship with Intermediate table (Table 2).

    But when i am processing, i am duplicate error from that table1.

    How to handle this situation.Kindly guide me.

    --------------------------------------------------------

    I am Learner -- SQL

  • Your use of an intermediate dimension is ineffective in this case. A dimension attribute's key has to be unique, but yours isn't because the code is repeated. Even the surrogate keys you've created are not unique, so they are not helping you at all.

    You will either need to generate some kind of code or surrogate key that will be unique for each record in the dimension, or change your attribute key to include the Status field.

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply