Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
377 views
in Technique[技术] by (71.8m points)

ssrs 2008 - Modified Reporting Services Report - RDL does not change?

I have a Reporting Services 2005 report that had an error: "Parameter UserID is read-only". After doing some research, I found a solution that worked. I opened the report from the Report Manager web interface and changed this:

before

..to this:

after

After this change, the report works! Great!

So, I figure I will download the modified RDL so I can see the change and get the corrected RDL into my source code repository. So, I download the RDL:

Downloading the RDL

But my diff tools tell me that the "before" version of the RDL is identical to the "after" version of the RDL. Convinced that my diff tool was mistaken, I tried another. Sure enough, there is no difference in the RDL.

What am I missing? Is the change reflected somewhere other than the RDL, or is Reporting Services not coughing up the correct version of the RDL? In either case, how can I get the correct version of the RDL?

Thank you.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

TL/DR Version: Reporting Services is not giving you the correct RDL.


Your question prompted me to further investigate a suspicion I already had on SSRS for quite some time: report parameters can behave in unexpected ways for report developers when deploying (or downloading) report definitions. One related scenario I had noted before:

  1. Create a report with parameters.
  2. Deploy the report for the first time.
  3. Update the report parameters in some way.
  4. Deploy the same report once more.
  5. Result: parameter settings are not succesfully updated on the server.
  6. Delete the report from the report manager.
  7. Deploy the report once more (effectively the same as step 2).
  8. Result: Report parameters are updated correctly.

In short, if you want to update parameter settings for deployed reports you'll first need to delete it and then deploy it, or update the settings directly via the report manager.

Back to your question(s). You're not missing anything, this just seems the way SSRS is behaving (intended or not). The RDL schema has this (abbreviated) piece:

<xsd:complexType name="ReportParameterType">
    <xsd:choice minOccurs="1" maxOccurs="unbounded">
        <xsd:element name="DataType">
            <!-- abbreviated -->
        </xsd:element>
        <xsd:element name="Nullable" type="xsd:boolean" minOccurs="0"/>
        <xsd:element name="DefaultValue" type="DefaultValueType" minOccurs="0"/>
        <xsd:element name="AllowBlank" type="xsd:boolean" minOccurs="0"/>
        <xsd:element name="Prompt" type="xsd:string" minOccurs="0"/>
        <xsd:element name="ValidValues" type="ValidValuesType" minOccurs="0"/>
        <xsd:element name="Hidden" type="xsd:boolean" minOccurs="0"/>
        <xsd:element name="MultiValue" type="xsd:boolean" minOccurs="0"/>
        <xsd:element name="UsedInQuery" minOccurs="0">
    </xsd:choice>
    <xsd:attribute name="Name" type="xsd:normalizedString" use="required"/>
</xsd:complexType>

So, there should be a "Hidden" element for your ReportParameter.

I just verified your findings (in SSRS 2008), and think I may have the answer to your second question: SSRS is indeed not coughing up the correct version of the RDL. It's missing various bits about the parameters, including the element on being hidden or not.

Funny thing is: if you change the report in BIDS and set the parameter to hidden, the RDL will be changed and have the <Hidden>true</Hidden> element.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...