Previous Topic

Book Contents

Book Index

Next Topic

Global Functions

Expert Search can use so-called Global Functions. Global functions are hard coded functions capable of retrieving special values for use in Valuemation conditions.

Based on actual needs, global functions have been created for the following data types:

  • integer
  • datetime
  • string

Global functions are data type specific, a set of functions exists for each of the supported data types.

Datetime

10 global functions have been defined for datetime attributes:

  • 1DayAgo, 2DaysAgo, 3DaysAgo, 5DaysAgo

    The functions retrieve a datetime value equal to the current datetime minus the specified number of days

  • 1WeekAgo, 2WeeksAgo

    The functions retrieve a datetime value equal to the current datetime minus the specified number of weeks

  • 3MonthsAgo, 6MonthsAgo

    The functions retrieve a datetime value equal to the current datetime minus the specified number of months

  • 1YearAgo, 2YearsAgo, 5YearsAgo, 10YearsAgo

    The functions retrieve a datetime value equal to the current datetime minus the specified number of years

  • acceptableTimeStampForActiveSession

    The function extracts a value from Valuemation mainparameter: path = UserSessionsLogging, parameter = TimeoutForInactiveClient

  • currentTimeStamp

    The function retrieves the current datetime value.

String

3 global functions have been defined for string attributes:

  • bpmCurrentLogonS3UserId

    The function retrieves user ID in a specific format used by the query of the 'Tasks for Me' catalog (Business Process Manager). It is used by condition 'Offered To - like - Value: bpmCurrentLogonS3UserId'.

  • currentLogonUserFirstname

    The function retrieves the first name of the currently logged in Valuemation user.

  • currentLogonUserLastname

    The function retrieves the last name of the currently logged in Valuemation user.

Integer

3 global functions have been defined for integer attributes:

  • currentAssociatedPersonId

    The function retrieves the primary key of the person object associated with the currently logged in Valuemation user.

  • currentLogonUserId

    The function retrieves the primary key of the currently logged in Valuemation user.

  • mainparamspo

    This is an obsolete function used previously for ticket 'subject-predicate-object' functionality.

Example of Use

Let's use a global function to quickly filter the catalog of incidents so that it only displays incidents reported no more than 3 days ago.

  1. Create an Expert Search row.
  2. Specify 'Date Reported: date and time' as 'Attribute' and 'equals or greater' as 'Operator'.
  3. Click in the 'Value' column. The 'Values' dialog opens. Make sure that the 'Value' radio button is selected and check the 'Use global function' check box.
  4. Use the drop down box in the 'Values' dialog to select a suitable global function.

    For example, let's select the '_3DaysAgo()' global function.

  5. Click 'Close' to finalize the value selection.
  6. Click 'Search' in the search catalog section.

    The catalog will be filtered to display only incidents reported 3 days ago or later.

See Also

Expert Search in Detail

Creating Condition Rows

Choose Attribute Dialog Box in Detail

Operators

Priority of Operators

Using Subqueries

Types of Attribute Values

Creating a Condition Directly in a Catalog

Catalog Query Selector

Value Checkbox

Case Sensitivity