Hi All,
I am getting this error when processing cube. I know that all the underlying Tables are empty (not having any data)
MdxScript(CubeName) (575, 33) The level '.&[Hero]' object was not found in the cube when the string, [product].[category].[bikes].&[Hero], was parsed.
When I checked Cube-Calculations found below scope which is causing this issue.
SCOPE (measures.[sales amount], [product].[category].[bikes].&[Hero],[Date].[Calendar].[Q4 CY 2002]);
THIS = ([product].[category].[bikes].&[Hero], [Date].[Calendar].[Q4 CY 2002]) *
1.3
END SCOPE;
I understood the reason of this error but not sure how to fix this? As my underlying tables are empty and so it is not able to find &[Hero] during process time and failing. But there is a possibility that tomorrow data related to Bikes Hero has been completely removed from underlying table and not going to be loading any more. In this case this scope will start throwing error. How to make sure even underlying data is there or not such SCOPE should not throw error?
I found this but not clear to me:
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/148bfc09-0af8-4c5d-9ab6-46758c138f98/conditional-mdx-?forum=sqlanalysisservices
SCOPE explained in nice Way:
https://www.sqlservergeeks.com/sql-server-implementing-calculations-in-ssas-using-mdx-part-3/
Thanks Shiven:) If Answer is Helpful, Please Vote