Suppress Formula based on Username

Printed From: Crystal Reports Book — Forum Name: Technical Questions

Hi everyone,

I am just starting to learn Crystal so forgive me if I am lacking any info. I have a suppress formula that suppresses a line item IF the line item is greater than one
(line item 1 {sales config template} always needs displayed, since it states the manufactured object model being ordered) AND if the line item has a choice assigned (ie not blank) OR, if the option's choice text contains "NO ELECTRIC PACKAGE".




{CRM_QUOTE_DETAIL.SALES_OPTION_CHOICE_ID} = 0
and {CRM_QUOTE_DETAIL.SEQ}>1
or {CRM_QUOTE_DETAIL.SOURCE_DISPLAY} = "NO ELECTRIC PACKAGE"




This works fine for our manufactured orders. However, for orders that just contain parts (no sales config template at line 1) it needs to display all items. So I thought maybe adding an exception for the parts salesmen user IDs. I got it to work perfectly for one user, but it gets screwy trying to add two user IDs.

Works fine:



{CRM_QUOTE_DETAIL.USERID} <> "DAVIS"
and {CRM_QUOTE_DETAIL.SALES_OPTION_CHOICE_ID} = 0
and {CRM_QUOTE_DETAIL.SEQ}>1
or {CRM_QUOTE_DETAIL.SOURCE_DISPLAY} = "NO ELECTRIC PACKAGE"



Needing something like:




{CRM_QUOTE_DETAIL.USERID} <> "DAVIS" or "JOHN"
and {CRM_QUOTE_DETAIL.SALES_OPTION_CHOICE_ID} = 0
and {CRM_QUOTE_DETAIL.SEQ}>1
or {CRM_QUOTE_DETAIL.SOURCE_DISPLAY} = "NO ELECTRIC PACKAGE"



Any way of specifying what user IDs to watch out for besides explicitly stating what usernames are the exception? Like a find(davis or john) formula? Thank you for your help.
(NOT({CRM_QUOTE_DETAIL.USERID} IN ["DAVIS","JOHN"]))
and {CRM_QUOTE_DETAIL.SALES_OPTION_CHOICE_ID} = 0
and {CRM_QUOTE_DETAIL.SEQ}>1
or {CRM_QUOTE_DETAIL.SOURCE_DISPLAY} = "NO ELECTRIC PACKAGE"