Quantcast
Channel: SQL Server Analysis Services forum
Viewing all articles
Browse latest Browse all 14337

Problems with Many-to-Many relationship when processing cube

$
0
0

For Reference:

Fact Table: Encounters, primary key: EncID

Cross Reference Table : Secondary Diagnosis, primary Key: EncId, DxId

Dimension: Diagnosis (DxId)

An encounter can have many Secondary Diagnosis, and a Secondary Diagnosis can belong to many different encounters.  Not all encounters will have a secondary diagnosis, and not all secondary diagnosis will have an encounter.

So basically datamodel in the mart looks like this

Encounter (EncId) ------> Secondary Diagnosis (EncID, DxID) <-------- Diagnosis (DxId)

In the cube to model this using a Many to Many relationship I created the Encounters Dim modeled below

Encounter Fact -----------> Encounters Dim <-------- Secondary Diagnosis (Fact) ----------> Diagnosis

When I process the cube, I get server processing errors stating the EncID XXXX is not found in Secondary Diagnosis fact, which is a true statement since not all encounters will have a secondary diagnosis.  Is there any way that I can model this so I do not get the processing errors.  The "Encounters Dim" I limited to only encounter ids that do have a secondary diagnonis, but that did not work.  Not sure what my best option is, or even if I have any.

THanks for your help



Viewing all articles
Browse latest Browse all 14337

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>