Peterson's Ponderings

Technical findings, ideas, thoughts and news directly from me.
in

August 2007 - Posts

Semantic Model Generator Error when creating a report model off of a SSAS cube

I recently experienced a really frustrating error when attempting to build a report model for SQL Server 2005 Reporting Services off of a SQL Server 2005 Analysis Services cube.  I kept getting the following error message:

w3wp!semanticmodelgenerator!5!08/28/2007-09:16:39:: e ERROR: Semantic Model Generator: ModelGeneratorExtention
An error occurred while executing rule 'Create attributes for dimension Customer ':Error Code = 0x80004005, External Code = 0x00000000:..

This cryptic error message gave me no hints as to what was really wrong and surprisingly there was nothing on the internet about it (until now!).  At first it sent me on a wild goose chase thinking there was something wrong with my Customer dimension defined in the SSAS cube.  But what could it be?  I couldn't find anything odd about the dimension as it was a straight forward dimension with a few basic hierarchies.  So at that point I removed the dimension from the cube altogether and alas got the same error when attempting to create a report model, but this time it said 'Create attributes for dimension Date '.  At this point I suspected the rule information it was showing with the error information was inaccurate so I had to do some deeper problem solving. 

What I eventually found to be the real cause of the error was the parent-child relationship I had defined in a Product dimension.  This dimension had two fields in the Product table that were keys back to the Product table.  One of the keys had its parent-child hierarchy relationship defined in the dimension already.  Once I removed the self referencing foreign keys and the parent-child hierarchy on the Product dimension (and after adding my Customer dimension back into the cube) the model was finally able to be generated.

I'm posting this in case anyone else runs into this cryptic and misleading error message during model generation.