Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 423
  • Last Modified:

Pass NULL along with selected parameter choice from dynamic parameter

How do I pass NULL along with the selected parameter value from a dynamic parameter?
I need to show all records that have the selected value for my field AND all records that have NULL for that field too.
I have this for my Select Expert - Record formula: ({Command.FYI FlagTypeID}={?FYI Flag} or isnull({Command.FYI FlagTypeID})or{Command.FYI FlagTypeID}=''). It just returns those records with a value, no records return with NULLs.

I changed it to ({Command.FYI FlagTypeID}={?FYI Flag} and isnull({Command.FYI FlagTypeID}) but no records returned at all.

Thanks in advance for your help!
1 Solution
A field cannot be NULL and have a value.  Also you have to test for the NULL first because Crystal terminates the evaluation when it tries to test a NULL field except for IsNull tests

Try it this way
      isnull({Command.FYI FlagTypeID} OR  {Command.FYI FlagTypeID}={?FYI Flag}


Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now