dbTalk Databases Forums  

Question about Report Parameters

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


Discuss Question about Report Parameters in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Durval Mateus
 
Posts: n/a

Default Question about Report Parameters - 12-13-2004 , 01:55 PM






I have a MDX query that queries a cube to retrieve the years available.

now, i want to add an "All Years" to my combo. how can i do that?

i'm making my report with report designer.

Reply With Quote
  #2  
Old   
Dan Reving
 
Posts: n/a

Default Re: Question about Report Parameters - 12-14-2004 , 11:12 AM






Besides the obvious solution by adding an all-level to your
time-dimension in your cube, you could do something like this:

(I don't know your actual query, but you hopefully get the idea)

With member [Time].[All Years] as 'Sum([Time].[Year].members)'
Select
{[Measures].members } on columns,
{[Time].[All Years], [Time].[year].members} on rows
From [Your Cube]

(You could substitute the "[Time].[All], [Time].[year].members"
expression by "AddCalculatedMembers([Time].[year].members)")

This obviously requires that your enter / modify the MDX-query by hand,
and that should be possible (if not mandatory ?) in the report designer,
as far as I know.

Regards
Dan Reving

Durval Mateus wrote:
Quote:
I have a MDX query that queries a cube to retrieve the years available.

now, i want to add an "All Years" to my combo. how can i do that?

i'm making my report with report designer.

Reply With Quote
  #3  
Old   
Durval Mateus
 
Posts: n/a

Default Re: Question about Report Parameters - 12-15-2004 , 11:35 AM



Hi Dan,

Thanks for the reply. it helped.

My problem is i'm new on this, and the MDX thing...

Regards,
Durval Mateus

"Dan Reving" wrote:

Quote:
Besides the obvious solution by adding an all-level to your
time-dimension in your cube, you could do something like this:

(I don't know your actual query, but you hopefully get the idea)

With member [Time].[All Years] as 'Sum([Time].[Year].members)'
Select
{[Measures].members } on columns,
{[Time].[All Years], [Time].[year].members} on rows
From [Your Cube]

(You could substitute the "[Time].[All], [Time].[year].members"
expression by "AddCalculatedMembers([Time].[year].members)")

This obviously requires that your enter / modify the MDX-query by hand,
and that should be possible (if not mandatory ?) in the report designer,
as far as I know.

Regards
Dan Reving

Durval Mateus wrote:
I have a MDX query that queries a cube to retrieve the years available.

now, i want to add an "All Years" to my combo. how can i do that?

i'm making my report with report designer.


Reply With Quote
  #4  
Old   
mike
 
Posts: n/a

Default Re: Question about Report Parameters - 12-15-2004 , 04:13 PM



/************************************************** *****
assumes you have a [Time] dimension
you'll get [All Time] member at top of your list, with the remaining [Time]
members filling out the rest of your list
************************************************** *****/
with
member [Time].[All Time] as '[Time].[All Time]'
member [Measures].[TimeCurrentMemberName] as '[Time].CurrentMember.Name'
select
{
[Measures].[TimeCurrentMemberName]
} on columns,
{
([Time].[All Time]*[Time])
} on rows
From YourCube

"Durval Mateus" wrote:

Quote:
Hi Dan,

Thanks for the reply. it helped.

My problem is i'm new on this, and the MDX thing...

Regards,
Durval Mateus

"Dan Reving" wrote:

Besides the obvious solution by adding an all-level to your
time-dimension in your cube, you could do something like this:

(I don't know your actual query, but you hopefully get the idea)

With member [Time].[All Years] as 'Sum([Time].[Year].members)'
Select
{[Measures].members } on columns,
{[Time].[All Years], [Time].[year].members} on rows
From [Your Cube]

(You could substitute the "[Time].[All], [Time].[year].members"
expression by "AddCalculatedMembers([Time].[year].members)")

This obviously requires that your enter / modify the MDX-query by hand,
and that should be possible (if not mandatory ?) in the report designer,
as far as I know.

Regards
Dan Reving

Durval Mateus wrote:
I have a MDX query that queries a cube to retrieve the years available.

now, i want to add an "All Years" to my combo. how can i do that?

i'm making my report with report designer.


Reply With Quote
  #5  
Old   
Durval Mateus
 
Posts: n/a

Default Re: Question about Report Parameters - 12-17-2004 , 10:05 AM



hi,

thanks for the reply, i have now what i want.

Regards,
Duval Mateus

"mike" wrote:

Quote:
/************************************************** *****
assumes you have a [Time] dimension
you'll get [All Time] member at top of your list, with the remaining [Time]
members filling out the rest of your list
************************************************** *****/
with
member [Time].[All Time] as '[Time].[All Time]'
member [Measures].[TimeCurrentMemberName] as '[Time].CurrentMember.Name'
select
{
[Measures].[TimeCurrentMemberName]
} on columns,
{
([Time].[All Time]*[Time])
} on rows
From YourCube

"Durval Mateus" wrote:

Hi Dan,

Thanks for the reply. it helped.

My problem is i'm new on this, and the MDX thing...

Regards,
Durval Mateus

"Dan Reving" wrote:

Besides the obvious solution by adding an all-level to your
time-dimension in your cube, you could do something like this:

(I don't know your actual query, but you hopefully get the idea)

With member [Time].[All Years] as 'Sum([Time].[Year].members)'
Select
{[Measures].members } on columns,
{[Time].[All Years], [Time].[year].members} on rows
From [Your Cube]

(You could substitute the "[Time].[All], [Time].[year].members"
expression by "AddCalculatedMembers([Time].[year].members)")

This obviously requires that your enter / modify the MDX-query by hand,
and that should be possible (if not mandatory ?) in the report designer,
as far as I know.

Regards
Dan Reving

Durval Mateus wrote:
I have a MDX query that queries a cube to retrieve the years available.

now, i want to add an "All Years" to my combo. how can i do that?

i'm making my report with report designer.


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.