Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
jrapp
Starting Member
9 Posts |
Posted - 2005-02-23 : 15:27:43
|
I'm using one stored procedure to produce multiple reports and would like to use the filtering functionality to pull just a portion of the data. Since I'm re-using the SP, I do not want to limit my data by the proc's where clause. I am using a table on my report, and going to the table's Properties>Filter tab and entering Field!Fruit.Value = 1 and RS gives me this error message when attempting to preview the report:An error has occurred during report processing. The processing of filter expression for the table 'Fruit' cannot be performed. The comparision failed. Please check the datatype returned by filter expression.The same result is produced if I use the Filter tab on the data set properties box or if I select the table's properties, filter property, and set the filter there. I have verified that the field passed by the proc is an integer. What am I doing wrong? |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2005-02-23 : 16:26:38
|
What have I done to get something like this to work is this:CInt(Field!Fruit.Value) = CInt(1)For some reason, RS isn't able to figure out it's an int sometimes on its own, so you force it.Tara |
 |
|
jrapp
Starting Member
9 Posts |
Posted - 2005-02-23 : 16:51:51
|
Thanks for the reply. Where would I force the value to an integer? In the filter expression? I have tried specifying the type in the data set's field tab, value expression for the field and the filter's tab for the data set with no success. The field I would like to filter on is not a field on the report - it's just in the data set.quote: Originally posted by tduggan What have I done to get something like this to work is this:CInt(Field!Fruit.Value) = CInt(1)For some reason, RS isn't able to figure out it's an int sometimes on its own, so you force it.Tara
|
 |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2005-02-23 : 18:23:02
|
Just because you aren't displaying the field in the report, that doesn't mean that it isn't a field. If it's available in the dataset, then it's available in the report as a field. I posted exactly what you will need in the filter tab. I posted the left side part and the right side part. Replace what you have in the filter tab with what I posted and see if you get an error still.Tara |
 |
|
jrapp
Starting Member
9 Posts |
Posted - 2005-02-23 : 18:26:28
|
I followed your instructions exactly. Still does not work. |
 |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2005-02-23 : 18:29:24
|
Do you have service pack 1 installed? If so, have you tried service pack 2 to see if it resolves your problem. sp2 is in Beta right now but I suspect it corrects a lot of bugs with RS as I've had to do a bunch of workarounds already due to various bugs.Tara |
 |
|
jrapp
Starting Member
9 Posts |
Posted - 2005-02-25 : 08:49:50
|
Beta SP 2 is not readily available without becoming a Beta Tester for MS. I've signed up. We'll see. If anyone one else comes up with a better solution....please post. Thanks!quote: Originally posted by tduggan Do you have service pack 1 installed? If so, have you tried service pack 2 to see if it resolves your problem. sp2 is in Beta right now but I suspect it corrects a lot of bugs with RS as I've had to do a bunch of workarounds already due to various bugs.Tara
|
 |
|
jrapp
Starting Member
9 Posts |
Posted - 2005-03-03 : 10:51:30
|
To date, I have not heard back from Microsoft. To any RS Beta tester that has already received SP2, can you zip it up and send it to rappjessica@hotmail.com? It would be greatly appreciated! |
 |
|
|
|
|
|
|