Partilhar via


Applying Filtering to a Class

This topic describes how to apply filtering to a class. Filtering enables the summarization to filter out data based on the value of a member of the base class.

In the clsdef table, set the value of the ClassType column to "3" for filtering. The value of the InstExclusionExpr column contains the expression string on which to filter. The filtering feature supports the IN and NOT IN operators that use the following syntax:

   Exclusion string = "BaseClassMemberName IN(value)"
   Exclusion string = "BaseClassMemberName NOT IN(value)"

The following examples show how to filter classes.

For information about how to extend the Data Warehouse, see Extending the Data Warehouse Logical Schema.

Example 1

'Set the class name.
   Set recNew = CreateObject("ADODB.Record")
   recNew("ClassDefName") = "NewRequestAgg"

'Set the class type to aggregation.
   recNew("ClassType") = 3

'Set the name of the base class to use for data.
   recNew("BaseClassName") = "Request"

'Set the exclusion string (filter).
'This excludes all data from the aggregation where IsRequest = 1.
   recNew("InstExclusionExpr") = "IsRequest IN(1)"

Example 2

'Set the class name.
   recNew("ClassDefName") = "NewHTTPStatustAgg"

'Set the class type to aggregation.
   recNew("ClassType") = 3

'Set the name of the base class to use for data.
   recNew("BaseClassName") = "Request"

'Set the exclusion string (filter).
'This excludes all hits that have an HTTPStatus not in the given set.
   recNew("InstExclusionExpr") = _
    "HttpStatus NOT IN(0,200,202,203,204,304)" 

See Also

Other Resources

Extending the Data Warehouse Logical Schema