How to refer PK Of Dimension table twice in a fact table

  • Hi all

    I want to relate a particular Primary key of dimension table twice as a foreign key, What is best possible way.

    e.g Date dimension has Datekey and my Fact tbl has two fields RECORD_DTEKEY , PAY_DTEKEY

    I could create one foreign key but not able to relate aging same key to another field in a fact table

    I hope you guys understood my problem.

    Thanks in advance

  • Why aren't you able to do this? Is the alter table for the second foreign key failing? (it shouldn't, same syntax will work for both) If so, with what error?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

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

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