Gearset has customizable metadata filters that control the types of metadata components that are displayed in the comparison results page. However, there are some cases where a more fine grained filter might be required. For example, hiding some fields based on their name.

You can do this in Gearset by using regex filters, either in the main filter or on any of the column filters. To use a regex filter, use the regex: operator in any of these filter inputs. You can negate the results with the not: operator.

In this example, we're applying a filter to the component name column. There's a custom object called RegexExample that exists in the source and target. The source object has some fields that don't exist in the target. These fields are:

Quantity

TEST_AccountNumber

TEST_Price

TEST_Quantity

To use a regex filter, using the regex: operator, followed by the regex string:

Now only fields with names beginning with TEST_ are included in the results:


To negate the results of a regex filter, use the not: operator together with the regex: operator:

In this example, only fields with names not beginning with TEST_ are included in the results:

To use several regex filters together, combine them with the | operator:
not:regex:TEST_|QA_|staging 

To apply the regex filter across all properties, not just the name, use the main filter input:

Note that using the regex: operator makes this filter case sensitive. Omitting the regex:  operator will revert to the basic case insensitive filter.

Did this answer your question?