Notes about Filtering on Types of Fields and Values | Salesforce
Notes about Filtering on Types of Fields and Values
Keep these tips in mind when filtering on text fields, date fields, numeric values, picklist values, and blank or null values.
Filtering on Text Fields
Separate search terms by commas to filter by more than one value. For example, to search for accounts in California, New York, or Washington, use State contains CA,NY,WA.
Filtering isn't case sensitive. For example, searching State contains ID returns all matches for “ID”, but also returns any instances of “Florida” and “Idaho” because they contain “id” in their names.
When you filter on standard long text area fields, such as Description or Solution Details, only the first 1000 characters of the field are searched for matches in reports. Reports can’t be filtered on custom long text area fields. Only the first 255 characters are shown for custom long text area fields in list views.
Filtering on Date Fields
If entering a date, use the format allowed by your Locale setting. You can also use special date values like TODAY, NEXT WEEK, NEXT YEAR, LAST <number> DAYS, and so on.
Filtering on Numeric Values
Place quotation marks around numbers or other data that includes commas. For example Amount equals "10,000" returns records that have an amount of $10,000 but Amount equals 10,000 returns $10,000 as well as $10 and $0.
To search for phone numbers, include the exact phone number formatting or example, Phone starts with (561).
Filtering on Picklist Values
When filtering on multi-select picklist fields, use a semicolon between values to specify an exact match.
For example, selecting the “equals” operator and a semicolon between two values includes records with both values specified, excluding all other values.
If your organization uses record types, the lookup dialog lists picklist values for all record types. Use the “equals” or “not equal to” operators for these filters.
If you change the label for a picklist value that’s used as a filter criterion, the picklist value is automatically removed from the filter criteria. For example, if your report contains a filter where Lead Source equals Email or Web and you change the picklist value Web to Referral, your report filter changes to Lead Source equals Email. If the changed picklist value was the only value specified for a particular filter, it continues to show up in your filters, but an error appears.
Filtering on Blank or Null Values
When you use the “less than,” "greater than,” “less or equal,” or “greater or equal” operators on fields that have numeric values, records with blank or “null” values are returned as if their value is zero (0). For example, if you create a workflow rule or a lead assignment rule for accounts with the criteria Annual Revenue less than 100000, account records match if their Annual Revenue is blank.
However, records with blank field values are not considered matches in report filters, custom list views, and account assignment rules (which assign accounts to territories).
To limit results to records that are blank or contain “null” values for a particular field, choose the field and the “equals” or “not equal to” operators, leaving the third field blank. For example, Amount equals returns records with blank amount fields. You can search for blank values or other specified values at the same time. For example, Amount equals 1,,2 returns records where the Amount is blank or contains the value “1” or “2”.