sql server reporting services:
Re-Post
Can somebody advise me if there is a known 'issue' with RS in that it
is best not to try and build parameters that are to be used as Guids?
I am getting:
"Default value or value provided for the report parameter 'year' is
not a valid value"
TIA
My rdl snippet:
<Query>
<DataSourceName>TRAN</DataSourceName>
<CommandText>SELECT cToP, interP, plu, med, fun, other, hosp,
statusShortDesc, yearShortDesc, locShortDesc, locTypeShortDesc,
yearID, statusID FROM dbo.viewAnnualSummary WHERE (yearID = @year) AND
(statusID = @status)</CommandText>
<QueryParameters>
<QueryParameter Name="@year">
<Value>=Parameters!year.Value</Value>
</QueryParameter>
<QueryParameter Name="@status">
<Value>=Parameters!status.Value</Value>
</QueryParameter>
</QueryParameters>
</Query>
my code snippet in client:
Dim parameters(1) As ConsumeReportService.ReportService.ParameterValue
parameters(0) = New ConsumeReportService.ReportService.ParameterValue
parameters(0).Name = "yearID"
parameters(0).Value = ddlYear.SelectedValue
parameters(1) = New ConsumeReportService.ReportService.ParameterValue
parameters(1).Name = "statusID"
parameters(1).Value = ddlStatus.SelectedValue
A bit of example SQL:
SELECT cToP, interP, plu, med, fun, other, hosp, statusShortDesc,
yearShortDesc, locShortDesc, locTypeShortDesc, yearID, statusID
FROM dbo.viewAnnualSummary
WHERE statusID = 'AADBC831-8585-4FDC-ABF7-E856E51EA789'
AND yearID = 'C72FCAE6-6202-4731-99BB-619AF62E382C'
Reply
Details: Show quoted text | View source | Unwrap Lines | Forward