Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
26
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.54 KB | None | 0 0
  1. The CUBEMEMBER function used an array of values for retrieving data:
  2. =CUBEMEMBER(“AW BI Cube”,{“[Date].[Calendar Weeks].[Calendar Year].&[2014]“,”[Account].[Accounts].&[47]“})
  3. The bolded segment above is the array. We know it’s an array because of the braces {} surrounding the values. The array has 2 values:
  4. [Date].[Calendar Weeks].[Calendar Year].&[2014]
  5. [Account].[Accounts].&[47]
  6. Because it’s an array we can’t simply replace &[2014] with &A1. Where A1 = [2015]. Excel won’t accept cell references within an array.
  7.  
  8.  
  9. =CUBEVALUE(“PowerPivot Data”,”[Sum of SalesAmount]”,”[Country].[Australia]”,”[Category].[Bikes]”,”[FiscalYear].[2006]”)
  10.  
  11. =CUBEVALUE(“PowerPivot Data”,”[Sum of SalesAmount]”,”[Country].[Australia]”,”[Category].[Accessories]”,”[FiscalYear].[2005]”)
  12.  
  13. So the criteria in cell B4 are going to be:
  14.  
  15. “[Country].[Australia]”,”[Category].[Bikes]”,”[FiscalYear].[2006]”
  16.  
  17. But I am using the contents of cells to drive my selections … so the correct syntax is:
  18.  
  19. “[Country].[“&$B$5&”]”,”[Category].[“&$B7&”]”,”[“&$C$5&”].[“&C$6&”]”
  20.  
  21. =CUBEMEMBER(“ThisWorkbookDataModel”,”[Category].[CategoryName].[All]”,”Grand Total”)
  22.  
  23. =CUBEMEMBER(“ThisWorkbookDataModel”,”[Poll Owner].[Gender].&[F]”)
  24.  
  25.  
  26. =CUBEVALUE(“ThisWorkbookDataModel”,$B$4,$B8,C$5,Slicer_Poll_Has_Submissions)
  27.  
  28.  
  29. =CUBEVALUE(“ThisWorkbookDataModel”,”[Measures].[Count of PollID]”,[Poll Owner].[Gender].&[F],[Category].[CategoryName].&[Entertainment],[Poll].[Poll Has Submissions].[ALL])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement