Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Parameter issue

Status
Not open for further replies.

ekta22

IS-IT--Management
May 3, 2004
359
US
Hi,

I have a very simple report based on an oracle stored procedure. I have two parameters for this report. My issue is that I get data when I enter both the parameters. If I just enter one parameter and leave the other blank or leave both blank I get no data. I want that if I don't enter any value for a parameter it should show me all the data. I am using crystal 11.
This is what I have in my Record Selection formula.
Code:
(IF ISNULL({?FAC_TYPE}) OR {?FAC_TYPE}="" THEN 
    TRUE
ELSE
    {?FAC_TYPE}={FSEFEQ.FAC_TYPE})
AND
(IF ISNULL({?FAC_BASE}) OR {FSEFEQ.FAC_BASE_IDENT}="" THEN
    TRUE
ELSE
    {?FAC_BASE}={FSEFEQ.FAC_BASE_IDENT})

Thanks,

-E
 
Not sure how you could leave a parameter blank in XI. Add a default of "None" for each parm and then change the record selection to:

(
if {?FAC_TYPE} <> "None" THEN
{?FAC_TYPE}={FSEFEQ.FAC_TYPE} else
if {?FAC_TYPE} = "None" then
true
) and
(
IF {?FAC_BASE} <> "None" THEN
{?FAC_BASE}={FSEFEQ.FAC_BASE_IDENT} else
IF {?FAC_BASE} ="None" then
true
)

-LB
 
Oh.. I didn'tknow that. Using XI for the first time. I have always used version 10. I did as you said but still same results.
 
Why are you using the record selection at all?

The SP should handle the choices, and likely is, hence your difficulties.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top