IDO:
this formula in a record select won't deliver what you are saying:
"...AND
(IsNull({your_date_field}) OR NOT {?Only_Null_Dates} )
This would ensure that if the user selected true for the date restriction option, only records with Null dates would be included. "
Since it is based on "OR" then it will always draw in Null fields...the parameter field would be irrelevant...
KPoore:
I would attack your problem in this manner:
create 2 parameters as was suggested:
{?selectCounty} selecting "ALL" or the county name...in my formula method you would also allow a partial name so that the user would not be forced to memorize the exact spelling of the county
the record select statement would be
uppercase({table.county}) like switch
(
uppercase({?selectCounty}) = "ALL","*",
true,uppercase({?selectCounty}) + "*"
)
An uppercase comparison eliminates any case sensitivity and "uppercase({?selectCounty}) + "*" " catches complete or partial spellings of the county"
As for null values...the above formula will not work for Null values and actually I think would render the formula unworkable period if you know nulls were allowed.
create the numeric parameter to give the option to show records {?ReportType}
1. show county records with null records
2. show county records without null records
3. show only null records
then your record select could be
if {?ReportType} = 1 then
( isnull({table.county}) or
uppercase({table.county}) like switch
(
uppercase({?selectCounty}) = "ALL","*",
true,uppercase({?selectCounty}) + "*"
)
)
else if {?ReportType} = 2 then
( not isnull({table.county}) and
uppercase({table.county}) like switch
(
uppercase({?selectCounty}) = "ALL","*",
true,uppercase({?selectCounty}) + "*"
)
)
else
isnull({table.county}) ; // this would be the default
I think that will do the trick.
hope this helps
Jim