|
|
Passing "null" in the URL for an Integer parameter. |
|
Author |
Message |
krellnor

|
Posted: Tue Jul 06 10:50:30 CDT 2004 |
Top |
SVCS >> Passing "null" in the URL for an Integer parameter.
Hello,
I've got a stored procedure that my report uses as a datasource. One of the parameters for the stored procedure is an Integer called "OfficeTypes". The stored procedure checks if OfficeTypes is null, and if it is it returns every record. I want to hide the "OfficeTypes" input on the report and pass a null value on the URL, however I can't seem to do this. My url is as follows:
"http://...&OfficeType:isnull=true"
I get the error message: "An attempt was made to set a report parameter 'OfficeTypeID-NULL' that is not defined in this report".
If I change my URL to the following:
"http://...&OfficeType=null"
I get the error message:"The value provided for the report parameter 'OfficeTypeID' is not valid for its type."
So the question is, how can you set an Integer parameter for a report to null using the URL? All help is welcome. Thanks.
---
Posted using Wimdows.net NntpNews Component -
Post Made from http://www.hide-link.com/ , Ratings, and Searching.
Information Technology332
|
|
|
|
 |
Nilesh

|
Posted: Tue Jul 06 10:50:30 CDT 2004 |
Top |
SVCS >> Passing "null" in the URL for an Integer parameter.
Hey Guys,
Could you please tell me how to use a stored procedure as the data source.
The problem that I am facing is, the fields returned by the stored procedure
are not getting listed in the fields window. I tried creating the fields
explicitly but it gave me an error that the required fields are not found in
the dataset.
Any pointers would be of lot of help.
thanks,
Nilesh
> Hello,
>
> I've got a stored procedure that my report uses as a datasource. One of
the parameters for the stored procedure is an Integer called "OfficeTypes".
The stored procedure checks if OfficeTypes is null, and if it is it returns
every record. I want to hide the "OfficeTypes" input on the report and pass
a null value on the URL, however I can't seem to do this. My url is as
follows:
> "http://...&OfficeType:isnull=true"
> I get the error message: "An attempt was made to set a report parameter
'OfficeTypeID-NULL' that is not defined in this report".
> If I change my URL to the following:
> "http://...&OfficeType=null"
> I get the error message:"The value provided for the report parameter
'OfficeTypeID' is not valid for its type."
> So the question is, how can you set an Integer parameter for a report to
null using the URL? All help is welcome. Thanks.
>
> ---
> Posted using Wimdows.net NntpNews Component -
>
> Post Made from http://www.SqlJunkies.com/newsgroups Our newsgroup engine
supports Post Alerts, Ratings, and Searching.
|
|
|
|
 |
Jason

|
Posted: Tue Jul 06 13:29:48 CDT 2004 |
Top |
SVCS >> Passing "null" in the URL for an Integer parameter.
I'm not very experienced so I'm not sure I'll be much help, but first off in
the "Data" tab of your report, are you setting the command type to "Stored
Procedure" or are you setting it "Text" and calling the EXEC storedProcedure
command? If the command type is stored procedure, I'm not sure what to tell
you. Whenever I add a stored procedure this way the fields for the sp
automatically are added to the parameters list for my report, and thus show
up on the reports window. You could always add some parameters to the
reports parameter list and then edit the data set "Parameters" properties to
point to the properties you added. If you still have questions, explain more
about how and what you've done.
> Hey Guys,
> Could you please tell me how to use a stored procedure as the data
source.
> The problem that I am facing is, the fields returned by the stored
procedure
> are not getting listed in the fields window. I tried creating the fields
> explicitly but it gave me an error that the required fields are not found
in
> the dataset.
> Any pointers would be of lot of help.
>
> thanks,
> Nilesh
>
>
>
> > Hello,
> >
> > I've got a stored procedure that my report uses as a datasource. One of
> the parameters for the stored procedure is an Integer called
"OfficeTypes".
> The stored procedure checks if OfficeTypes is null, and if it is it
returns
> every record. I want to hide the "OfficeTypes" input on the report and
pass
> a null value on the URL, however I can't seem to do this. My url is as
> follows:
> > "http://...&OfficeType:isnull=true"
> > I get the error message: "An attempt was made to set a report parameter
> 'OfficeTypeID-NULL' that is not defined in this report".
> > If I change my URL to the following:
> > "http://...&OfficeType=null"
> > I get the error message:"The value provided for the report parameter
> 'OfficeTypeID' is not valid for its type."
> > So the question is, how can you set an Integer parameter for a report to
> null using the URL? All help is welcome. Thanks.
> >
> > ---
> > Posted using Wimdows.net NntpNews Component -
> >
> > Post Made from http://www.SqlJunkies.com/newsgroups Our newsgroup engine
> supports Post Alerts, Ratings, and Searching.
>
>
|
|
|
|
 |
|
|