FilterValues Class Methods

In this section, the FilterValues class methods are presented in alphabetical order.

Syntax

Equals()

Description

Use the Equals method to set the equal filter of Insights dashboards.

Parameters

None.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt.Equals().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True).Value("15041");

Syntax

EqualsDateTime(&DtTm)

Description

Use the EqualsDateTime method to set the date and time filter of Insights dashboards.

Parameters

Parameter

Description

&DtTm

Specifies date and time (as a datetime).

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt.Key("ORCL_ES_LAST_MODIFIED_DATE", "", True).EqualsDateTime(%Datetime);

Syntax

Exists()

Description

Use the Exists method to set a filter to check for the specified key. It returns all documents that contain the specified key.

Parameters

None.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt = &filt.Exists().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True);

Syntax

FilterValues()

Description

Use the FilterValues method to create a filter.

Parameters

None.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();

Syntax

InBetweenDateTime(&FromDtTm,&ToDtTm)

Description

Use the InBetweenDateTime method to set the date and time range filter of Insights dashboards.

Parameters

Parameter

Description

&FromDtTm

Specifies the from date and time part of a date range in the form of datetime.

&ToDtTm

Specifies the to date and time part of a date range in the form of datetime.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
Local datetime &FromDtTm = DateTimeValue("2000-01-01 19:20:30.000");
&filt.Key("ORCL_ES_LAST_MODIFIED_DATE", "", True).InBetweenDateTime(&FromDtTm, %Datetime);

Syntax

Key(&sKey,&sKeyLabel,&isRLR)

Description

Use the Key method to set the key or field, which is used with other methods that take the key value to filter data, such as Equals, NotEquals, and so on.

Parameters

Parameter

Description

&sKey

Specifies the key as a String.

&sKeyLabel

Specifies the label of a key as a String.

&isRLR

Specifies whether the value should be translated in the related language table. If you enter True, the value is translated; False, otherwise.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
/*Create a string sArrVals with array of strings */
&filt.Equals().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True).Values(&sArrVals);

Syntax

NotEquals()

Description

Use the NotEquals method to filter data by checking whether a specified key does not match the specified value.

Parameters

None.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt.NotEquals().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True).Value("15041");

Syntax

NotEqualsDateTime(&DtTm)

Description

Use the NotEqualsDateTime method to set the not equal to date and time filter of Insights dashboards.

Parameters

Parameter

Description

&DtTm

Specifies date and time (as a Datetime).

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt.Key("ORCL_ES_LAST_MODIFIED_DATE", "", True).NotEqualsDateTime(%Datetime);

Syntax

NotExists()

Description

Use the NotExists method to determine whether the specified key does not exist.

Parameters

None.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt = &filt.NotExists().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True);

Syntax

NotInBetweenDateTime(&FromDtTm,&ToDtTm)

Description

Use the NotInBetweenDateTime method to set the date and time filter of Insights dashboards that exclude the specified date and time range.

Parameters

Parameter

Description

&FromDtTm

Specifies the from date and time part of a date range in the form of datetime.

&ToDtTm

Specifies the to date and time part of a date range in the form of datetime.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
Local datetime &FromDtTm = DateTimeValue("2000-01-01 19:20:30.000");
&filt.Key("ORCL_ES_LAST_MODIFIED_DATE", "", True).NotInBetweenDateTime(&FromDtTm, %Datetime);

Syntax

Value(&sVal)

Description

Use the Value method to set a single value for a filter of Insights dashboards.

Parameters

Parameter

Description

&sVal

Specifies the value as a String.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
&filt.Equals().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True).Value("15041");

Syntax

Values(&sArrVals)

Description

Use the Values method to set multiple values for a filter of Insights dashboards.

Parameters

Parameter

Description

&sArrVals

Specifies the value as an array of String.

Returns

A FilterValues object.

Example

import PTSF_INSIGHTS:FilterValues;

Local PTSF_INSIGHTS:FilterValues &filt = create PTSF_INSIGHTS:FilterValues();
/*Create a string sArrVals with array of strings */
&filt.Equals().Key("INV_ITEM_ID_ORCL_ES_ENG", "", True).Values(&sArrVals);