Odpovědět Reporting Action and URL parameters

  • 9. září 2009 15:00
     
     
    I'm developing some new reporting actions with SSAS 2008 and SSRS 2008.  I've only done a few before.  With these new ones, I need to pass in member names for members containing special HTML characters like ampersands and colons and the like.  Obviously, this does not work out when trying to build the URL query string to SSRS.  The special characters are invalidating the URL.  What are the best practices for formatting these strings correctly?

Všechny reakce

  • 9. září 2009 15:13
    Moderátor
     
     Odpovědět
    You can use the MDX function: UrlEscapeFragment, as discussed in this earlier Forum thread:

    Using a report action and passing a report parameter

    Take a look at the "Sales Reason Comparisons" Reporting Action in the Adventure Works cube. The Target Type is attribute members, with the Target Object being [Product].[Category]. If you click and expand the optional "Parameters" area, the name of the parameter passed to the report is: "ProductCategory"

    And the parameter value passed to the report is:

    UrlEscapeFragment( [Product].[Category].CurrentMember.UniqueName )

    The UrlEscapeFragment MDX function will appropriately add the escape characters needed for a URL parameter.


    - Deepak
    • Označen jako odpověď cincysql 9. září 2009 15:24
    •  
  • 9. září 2009 15:24
     
     
    Perfect, thanks!
  • 8. května 2012 7:31
     
     

    Hi

    I have a problem passing a parameter.

    I created a report action

    which appears in the right place when I right click on the cell

    until I try to add a parameter.  Then the report action disappears.  Below is a screen dump.

    Please assist

    Thanks in advance

    Nikki


    NIkki