Filtering on a lookup attribute in Report Model

January 21, 2009

I’ve recently created a Report Model with a Lookup Entity in it. I saw to it that I had only one default detail attribute for it, and I gave that attribute a ValueSelection of list.
When I used the Report Model, I saw the attribute fine (as if it was inside the main Entity) but when I tried to filter on it I saw the Lookup Entity I was trying to hide and a filtered list. I couldn’t understand why that was. I went back to check the attribute. Its ValueSelection was of type list. I went to the role that was created in the main Entity and set it’s ValueSelection to list as well. That also didn’t help. Finally, I went to look at the Lookup Entity that the attribute originated from. It had an InstanceSelection property of filtered list. Changing that to type of list did the trick.

Add comment
facebook linkedin twitter email

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>



  1. Alexander KleinwaechterApril 14, 2009 讘 16:18

    Hi Ella,

    I like your Blog, because I stumble over exact the same issues within Reporting Services.

    Now I have a problem with the Lookup Entity when the ID field in the main table is nullable. I can’t filter the records of the main table with NULL values in the ID field when using a parameter in the filter. Do you know an easy solution?

    Best regards
    Alexander Kleinwaechter
    Doctors without Borders

  2. Ella MaschiachApril 15, 2009 讘 19:17

    Hi Alexander,

    I admit I haven’t tried to re-create your problem. Instead, I’d like to offer another approach. In my tables, if I need a fictitious ID for an entity, I usually use ‘-1’ as that would never be an Identity Number for a worker (for instance). Perhaps it’d be possible to update the table accordingly? I’m sure Report Builder wouldn’t have a problem with that sort of value.

    Hope that helps,

  3. Alexander KleinwaechterApril 29, 2009 讘 14:54

    That does the trick! Thanks a lot!