Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Help with Hasvalue Function in 2008

Dear all,

I have a question regarding "Hasvalue" function under Crystal Reports 2008. I have created a quite extensive report based on quite alot of parameters. These parameters need to be Optional i.e. if user does not enter a value then all the records according to date parameter should be chosen, however if any one parameter value has been entered then report should filter according to that parameter value as well as date parameter values.

The report prints out results fine however it takes quite a lot of time to load. Example would be, yesterday when I ran the report Database query took 87238ms and reading records took 30691ms hence report formatting a first page took 981428ms.

Upon research and help from Brian in this forum I found out that while using "Hasvalue" the even when I use parameter value in one of the parameters, only date parameters are getting passed through the SQL query to the database, rest are not passed meaning that it reads all the records and then sort them in the end.

I have only one parameter which is not optional and that is date parameter, rest all are optional.

My question is, how can I pass the parameter values when chosen through the SQL query so that it can search the db upon query and not read all the records and sort at last.

Any ideas how to make it work?

Many thanks

Regards

Jehanzeb

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question