Showing posts with label filter. Show all posts
Showing posts with label filter. Show all posts

Wednesday, March 7, 2012

Creating a filter on a Dataset

Can I create a report parameter label list to only show the values
that have been extracted wthin a field in my dataset?
i.e. in the same way you add an autofilter on a column in excel, to
return the values in that column.You would need to have a second dataset. Make it exactly the same except use
the distinct and just the single field you care about.
Of course if you are doing this, then your main dataset should take this and
use it as a query parameter so return as little data as possible. Stay away
from filters as much as possible.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Andy" <andywilliams1971@.msn.com> wrote in message
news:17287b26-fbc2-4442-a6f2-ba6cfdd83718@.u10g2000prn.googlegroups.com...
> Can I create a report parameter label list to only show the values
> that have been extracted wthin a field in my dataset?
> i.e. in the same way you add an autofilter on a column in excel, to
> return the values in that column.

Friday, February 24, 2012

Creating a calculated measure that filters

Hi,

Can I create a calculated member that will filter out based on a certain dimension? eg, I have a customer dimension and a sales cube. The sales cube has the sales count measure. Can I have a calculated measure that will give me the sales count for all customers that are flagged as 'New'? That way, I have a total count and a New customer count.

Thanks,

Brian

This should be very easy to do in MDX if you have attribute NewCustomer in the Customer dimension. The expression then would be something like

(Measures.[Sales Count], Customer.NewCustomer.[true])

|||

Thanks Mosha, indeed it is easy! I'd like to expand on this.

So, by adding a new calculated member, (Measures.[Sales Count], Customer.NewCustomer.[true]), it will give me the counts of new customers. Is is possible to now also filter on, say, customerStatus as well? eg.

My Sales cube also has a CustomerType dimension. How can I expand the filter above to also filter on the CustomerType dimension (say, customertype = E).

I'm still trying to get my head around MDX :)

Thanks!

Brian

|||I wouldn't call this "expansion" of the filter, it is more of "restricting" the filter further. Yes, you can add as many hierarchy members to the filter as you want. I recommend going over first few chapters of my "Fast Track to MDX" book to get yourself on the MDX track fast...