Skip to Content
Aug 22, 2009 at 09:04 AM

Permit a null date parameter



I'm converting a number (1,000+) CR9 reports for use in BOXI 3.1 and have run into a problem with some of them. The problematic ones all have static parameters that historically have also been able to accept a null value. Typically these are date parameters and simply clearing the default parameter value in BOXI means that the user is prompted for a value when viewing the report. The design of the report has a formulae field set up that takes the value of the parameter and if it is null then it uses the current date.

I would like to maintain this option for the end users to enable them to, by default, use todays date but I don't know how to send a null from BOXI 3.1 to Crystal Reports.

I've seen SAP Note 1337660, but this seems to relate to passing a null to a record selection formulae and I suspect that it won't work for date parameters anyway.

The only solution I can think of is to amend the reports so that rather than looking for a null value they look for a 'magic' date (probably some time in the past) and if that value is passed then they actually use todays date as per the current formulae. I could then put this 'magic' date into the default value of the parameter and hence BOXI so that the user doesn't have to remember this 'magic' date. Two things that I don't like about this possible solution are that I'm going to have to amend a lot of reports and secondly I don't like the idea of 'magic' numbers as they quickly lose their meaning.

Can anyone suggest a way that BOXI might be able to pass null values to a Crystal Reports static date parameter, or another more sensible way I can resolve this issue?