dbTalk Databases Forums  

Can I retrieve top members in security context using MDX?

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Can I retrieve top members in security context using MDX? in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Henk van der Meer
 
Posts: n/a

Default Can I retrieve top members in security context using MDX? - 04-05-2004 , 11:00 AM






I am writing an application that uses a tree control to display
dimension members. Because some dimensions have a ton of members, I
only want to load the first level that a user has access to and then
make round-trips to get the children as the user navigates down.

If a user has rights to members at different levels of the dimension,
I want to display the top-most members of each branch in the root of
my control.

Let's say this is my dimension

111
AAA
aaa
BBB
bbb
222
CCC
ccc
DDD
ddd

If a user has rights to [111] and all its children but only [DDD] in
the second branch, my control will display like so

+111

+DDD

Currently, I retrieve all the members a user has rights to and then
loop thru the set to find those members whose parents are not in the
set. This is expensive on resources and time on my web server.

Is there a way in MDX to return just these top-most members?

Reply With Quote
  #2  
Old   
Mosha Pasumansky [MS]
 
Posts: n/a

Default Re: Can I retrieve top members in security context using MDX? - 04-07-2004 , 03:59 AM






Actually, I don't think you can set up dimension security to have access to
[111] + children and [DDD].
In dimension security, the resulting dimension still has to be balanced by
levels, so your scenario probably cannot happen.

--
==================================================
Mosha Pasumansky - http://www.mosha.com/msolap
Development Lead in the Analysis Server team
All you need is love (John Lennon)
Disclaimer : This posting is provided "AS IS" with no warranties, and
confers no rights.
==================================================

"Henk van der Meer" <hvanderm (AT) ncen (DOT) com> wrote

Quote:
I am writing an application that uses a tree control to display
dimension members. Because some dimensions have a ton of members, I
only want to load the first level that a user has access to and then
make round-trips to get the children as the user navigates down.

If a user has rights to members at different levels of the dimension,
I want to display the top-most members of each branch in the root of
my control.

Let's say this is my dimension

111
AAA
aaa
BBB
bbb
222
CCC
ccc
DDD
ddd

If a user has rights to [111] and all its children but only [DDD] in
the second branch, my control will display like so

+111

+DDD

Currently, I retrieve all the members a user has rights to and then
loop thru the set to find those members whose parents are not in the
set. This is expensive on resources and time on my web server.

Is there a way in MDX to return just these top-most members?



Reply With Quote
  #3  
Old   
Henk van der Meer
 
Posts: n/a

Default Re: Can I retrieve top members in security context using MDX? - 04-07-2004 , 10:36 AM



Mosha,

Thanks for responding to me, perhaps I misspoke... I have cell level
security with Allowed Members set up for roles. The allowed members
set for the user above would be {[111],[DDD]}

In my application I request all {[Dimension].members} and rely on the
database security to limit the the allowed set to {[111],[DDD]}. This
works great because otherwise I'd have to maintain a second set of
security rights on the app layer.

The problem is some of the dimensions, Time for example, are large and
chances are the user only wants to see a specific segment not the
whole tree. So I only want to retrieve the topmost members based on
their rights and make round trips to the server for the children on
demand.

Hopefully I've explained my situation better here and thanks again for
your help.

-Henk

"Mosha Pasumansky [MS]" <moshap (AT) online (DOT) microsoft.com> wrote

Quote:
Actually, I don't think you can set up dimension security to have access to
[111] + children and [DDD].
In dimension security, the resulting dimension still has to be balanced by
levels, so your scenario probably cannot happen.

--
==================================================
Mosha Pasumansky - http://www.mosha.com/msolap
Development Lead in the Analysis Server team
All you need is love (John Lennon)
Disclaimer : This posting is provided "AS IS" with no warranties, and
confers no rights.
==================================================

"Henk van der Meer" <hvanderm (AT) ncen (DOT) com> wrote in message
news:3873d41a.0404050800.c02ac88 (AT) posting (DOT) google.com...
I am writing an application that uses a tree control to display
dimension members. Because some dimensions have a ton of members, I
only want to load the first level that a user has access to and then
make round-trips to get the children as the user navigates down.

If a user has rights to members at different levels of the dimension,
I want to display the top-most members of each branch in the root of
my control.

Let's say this is my dimension

111
AAA
aaa
BBB
bbb
222
CCC
ccc
DDD
ddd

If a user has rights to [111] and all its children but only [DDD] in
the second branch, my control will display like so

+111

+DDD

Currently, I retrieve all the members a user has rights to and then
loop thru the set to find those members whose parents are not in the
set. This is expensive on resources and time on my web server.

Is there a way in MDX to return just these top-most members?

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.