In my case there was a Scenario to link the Store Dimension with Domain Users and provide the data security in Excel, PPS Dashboard for the users who has the access only to the Stores.
This article was quite helpful.
http://www.rdacorp.com/2009/01/advanced-dimension-data-security-with-sql-server-2008/
Here the Key thing is pass the Application Domain user name into Cube as follows..
NONEMPTY([Store].[StoreName].MEMBERS,
(STRTOMEMBER("[User].[User Name].&[" + USERNAME+ "]"),
[Measures].[User Store Count]
))
Note: This script should be entered in Role -> Dimension Data(Cube Dimension not the OLAP Database Dimension) -> Advance tab.
In case you specify this script in Dimension Data tab under Cube Dimension then you will get this error.
"The browser is disabled because custom MDX expressions defined in the Advanced tab were not validated due to the following problem:
A connection cannot be made. Ensure that the server is running."
Friday, May 30, 2014
Sunday, November 10, 2013
Create Dynamic Get storedprocedure for All the tables
--- This can be customized as per the Requirments ------
-- This Script used to create the Get(select all columns) Procedure for all the database tables.
----------------------------------------------------------------------------------------------------
SELECT
' CREATE PROCEDURE [USP_GET_' + TBL.NAME + ']' +
+ ' AS
BEGIN
SELECT ' + LEFT(COLUMNS,LEN(COLUMNS)- 1) + CHAR(10) +
' , GETDATE() AS INSERTED_DATE
FROM ' + TBL.NAME +
'
END
GO
'
FROM SYS.TABLES AS TBL
CROSS APPLY
(
SELECT UPPER('[' + COL.NAME + ']') + ' ,'
FROM SYS.COLUMNS AS COL
WHERE COL.OBJECT_ID = TBL.OBJECT_ID
FOR XML PATH('')) AS TABLE_COLUMN(COLUMNS)
ORDER BY TBL.NAME ASC
Subscribe to:
Posts (Atom)
