Search code examples
crystal-reports

Crystal reports supress row is text "like"


This is something that I just don't get. My details contain a list of events. And in the Supress of the Details I have the following formula. Why the following code works

 {@Event} like 'Event_1*' or
 {@Event} like 'Event_2*' or
 {@Event} like 'Event_3*' or
 {@Event} like "-"

and I get only the events which their names are NOT "Event1-3" or "-" but the following code is not working and the detail section is suppressed even though I there are events named "Event1-3"

(Not({@Event} like 'Event_1*')) or
(Not({@Event} like 'Event_2*')) or
(Not({@Event} like 'Event_3*')) or
{@Event} like "-"

What I want to do is suppress all of the events that their names are NOT "Event1-3"

Thank you very much for any help!


Solution

  • Basic boolen algebra - to negate entire expression A or B you can use either not(A or B) or not A and not B :)