Advanced Creating / Editing Filters - Premium Edition Only

Filters provide you a way to limit the number of rows that are displayed, which is helpful when you are trying to zero in on a problem.

The Premium Edition allows you to use text based strings to filter your results, similar to an SQL query. The advanced filter edit box is displayed below the toolbar and allows you to enter your filter string.

 

Filter strings are made up of column names, operators and values. Below are some sample filter strings:

[column name] [operator] [value] - this is the format of a filter

level equals Error

level = Error or level = Warning

message contains "important info"

message <> "important info"

message contains "important info" or message contains hello

message not contains "important info"

message !<> "important info"

date > 2016-23-10

date > 2016-23-10 and date < 2016-24-10

((level = info and logger contains LogFile) or (level = Warning or level = Error)) and date > 2016-23-10

 

Column Names - the list of valid column names come from the Log File Parser that you created to parse your log file. Any column in the Parser can be used in the filter.

NOTE: You cannot filter on delta times since their values are dynamic and are based on the displayed rows.

equals

  Include rows where the match string matches the entire column value

=

  Same as "equals"
not equal   Include rows where the match string does NOT match the entire column value
!=   Same as "not equal"
contains   Include rows where the match string is found anywhere in the column value
<>   Same as "contains"
not contains   Include rows where the match string is NOT found anywhere in the column value
!<>   Same as "not contains"
>   Include rows if the value in the column is greater than the match string
>=   Include rows if the value in the column is greater than or equal to the match string
<   Include rows if the value in the column is less than the match string
<=   Include rows if the value in the column is less than or equal to the match string

NOTE: All comparisons are case insensitive.

 

Match String - match strings can be any text you want to check the column's value against. 

NOTE: If a value you are comparing against has spaces or tabs in it or the value is blank use quotes around your value in the filter.

 

Operators between clauses - there are only two operators that and join clauses, 'and' and 'or'. 

    *** need a table

and the clause on the left and the clause on the right must both be true for the line to be shown

or if either the clause on the left or the clause on the right is true true for the line to be shown

 

Parenthesis and order of precedence - clauses are evaluated from left to right

You can use parenthesis' to control the way clauses are grouped. Below are some examples:

level = Warning and date > 2016-23-10 or level = Error

In the above example any time the level equals error the line will be displayed regardless of the date value.

(level = Warning or level = Error) and date > 2016-23-10

You can change that with parenthesis, now in the above example first the level value is checked to be either Error or Warning. Then if that is a match an additional check is performed on the date and if it passes the test the line is displayed.

 

((level = info and logger contains LogFile) or (level = Warning or level = Error)) and date > 2016-23-10

 In this example multiple levels of parenthesis are used. The clause in the outer most parenthesis must be true AND the date must be be greater than 2016-23-10.

 

Filter toolbar and menu commands

If you have defined a severity column and have also setup your Application Preferences to show some severity filters on the toolbar you can add/remove a specified severity filter by simply clicking on the icon on the toolbar. A blue box is drawn around the bitmap if the filter is enabled.

Undo/Redo are available from the Filter menu and also on the toolbar but they behave differently.

  • Undo/Redo from the toolbar - remove and reapply the last filter that was successfully applied.
  • Undo/Redo next to the filter string - remove and reapply the last value entered in the filter string. It could be a single character or it could be an entire clause that was pasted in or was inserted by using the severity filter buttons.

 

Adding filters using the context menu

If you right click on a row in the grid a context menu is displayed. One of the options is "Column Filter". If you apply a filter from here the current column value is used as the filter string while the filter compare type is selected from the sub popup menu. If you click on a date, time ,or delta column the date filter options are enabled allowing you to quickly create a date filter.

 

Help with creating filters

As you type your filter text you will receive help with creating you filter. Intellisense shows you a list of columns and operators as you type.

A status field below the filter shows help text about the current state of the filter.

In addition the color surrounding the filter string changes to show the current state of the filter.

  • Blue indicates the filter being displayed is being applied.
  • Green indicates that you have a valid filter entered but it hasn't been applied yet.
  • Red indicates that there is an error with the current filter string.

Get the latest version of GamutLogViewer© today - click here!