Monday, March 12, 2012

How to add more search criteria in report?

Hi All,
I need to add more search criteria in the report for refining search (Such
as like, not like, exclude, bigger than, etc.), Could reporting services
realize it? And how?
Thanks a lot
BillYes, you could pull this off. Might be messy. You would in essence create
parameters that contained your criteria.
Param1
Param1_Criteria
Param1_Value
So PARAM1 would be selecting say a field in the data, say Order quantity.
Param1_Criteria would be a selection of the different operators(<, >, =,
LIKE).
Param1_value would be your value: (100, 200, WALNUT)
Then, I would suggest using filters(unless you are running against a SQL
Server DB, then using the actual SQL might be okay). But in the filters just
construct your filter based on the parameters to get you the correct result
set. The filters could be a bit complicated, but you should be able to
figure it out. If not, just reply, and I can offer more advice.
"Bill" wrote:
> Hi All,
> I need to add more search criteria in the report for refining search (Such
> as like, not like, exclude, bigger than, etc.), Could reporting services
> realize it? And how?
> Thanks a lot
> Bill
>
>|||I would create stored procedures that encapsulates your query. This approach
gives you more freedom inside stored procudure to manipulate user supplied
parmaters befotr using them in query.
Frankly, there is no limit to what you can do with SQL SELECT once inside
stored procedure.
"Bill" wrote:
> Hi All,
> I need to add more search criteria in the report for refining search (Such
> as like, not like, exclude, bigger than, etc.), Could reporting services
> realize it? And how?
> Thanks a lot
> Bill
>
>|||Personally I would use stored procedures. The user supplied parameters can
be manipulated prior to using them in SQL statements. Frankly, there is
nothing you couldn't do inside stored procredure.
"Bill" wrote:
> Hi All,
> I need to add more search criteria in the report for refining search (Such
> as like, not like, exclude, bigger than, etc.), Could reporting services
> realize it? And how?
> Thanks a lot
> Bill
>
>

No comments:

Post a Comment