Report Definition Reference

This topic describes the tabs in the Report Definition window in detail.

Report Definition Tab

The Report Definition tab lets you specify the query that will serve as the source of the report's data and indicate a maximum number of rows to retrieve.

The following fields are specific to Report Definitions.

Field Description
Query The query used to generate the report. You can specify a filter or custom SQL.
Limit The maximum number of rows you want to retrieve.

Parameters Tab

In addition to its usual functionality, the Parameters tab for Report Definitions lets you create parameters that can be compared to specific column values in the Selections tab.

Note: If you want to compare a parameter value to values in a table column, the Type of the parameter must match the data type of the table column.

Columns Tab

The Columns tab lets you choose which columns you want to include in the report, and in what order they should display. Column order in the report is from top to bottom. You can reorder column rows by clicking the arrows in the second column.

You use REL functions to further format the values in the Values column.

Field Description
Name The name of a column in the report. This does not have to match the real column name.
Description A description of the column.
Documentation A comment about the column.
Display Lets you control whether each column be displayed in the report.
Column Format

Lets you control how the column is formatted in HTML output. The options are as follows.

  • Raw: Displays the data as it is stored in the database.

  • Formatted: Displays the data in a user-friendly format.

  • Business Key: Displays the business key of the object, instead of its name.

  • Permalink: Displays the full PermaLink instead of the data.

  • Permalink business key: Displays a business key that links (via PermaLink) to the actual object

Value

Lets you use REL expressions to format the value. For example, the Formatted value of Job.RunTime is in milliseconds, but if you specify Time.formatDuration(Job.RunTime), you can reformat the Job.RunTime value into hours, minutes, seconds, and milliseconds.

For DateTimeZone columns, you can use the Time.expression(<dtz_column>, '<expression>') function to alter a value. For example =Time.expression(Job.RunStart, 'add 1 hour') adds an hour to the value. Leaving the <expression> parameter empty displays the date/time in its time zone.

If you want to select a date/time and the time zone is not GMT, make sure the time zone column is available on the Columns tab, or the time will be displayed in the GMT time zone.

Note: Column formatting affects only HTML output.

Selections Tab

The Selections tab lets you refine the report query by returning only rows that match specific criteria.

Each row in the Selections tab represents a comparison operation of some kind. For example, to limit the query to objects that were created before a specific date, you could choose the object's creation date column on the left, choose Less Than from the Operation field, choose Value from the Type field, and then specify a date Value as either a hard-coded value or a REL expression.

The Selections tab lets you compare values from different columns with each other using a hard-coded value or report parameter. The following operations can be used to compare values.

Field Description
Left Report Column Lets you choose a column for comparison.
Operation
  • Equal To: Values must be equal.
  • Not Equal To: Values must be different.
  • Matches Regex: Used with Value or Report Parameter only. The value of the Left Report Column must match the provided regular expression.
  • Not Matches Regex: Used with Value or Report Parameter only. The value of the Left Report Column must not match the provided regular expression.
  • In Range: Used with Value or Report Parameter only. The value of the Left Report Column must match the provided range expression.
  • Not In Range: Used with Value or Report Parameter only. The value of the Left Report Column must not match the provided range expression.
  • Greater Than: The value of the Left Report Column must be greater than the provided value of the Column, Value, or Report Parameter.
  • Less Than: The value of the Left Report Column must be smaller than the provided value of the Column, Value, or Report Parameter.
  • Greater Than Or Equal: The value of the Left Report Column must be greater than or equal to the provided value of the Column, Value, or Report Parameter.
  • Less Than Or Equal: The value of the Left Report Column must be smaller than or equal to the provided value of the Column, Value, or Report Parameter.
Type

Lets you specify the source of the value you want to compare to the Left Report Column value. The options are as follows.

  • Column: Lets you specify a different column in the query results.

  • Parameter: Lets you specify a parameter. The value of the parameter is compared to the values in the Left Report Column.

  • Value: Lets you specify a value or REL expression.

Value Lets you specify the column, value, or parameter (depending on the selected Type) that you want to compare to the Left Report Column value.

Sorts Tab

The Sorts tab lets you set the order of query results by sorting them on one or more columns. Sort rules are evaluated from top to bottom. You can reorder sort rules by clicking the arrows in the second column.

Field Description
Report Column The column on which to sort.
Ascending Check this box to do an ascending sort, or leave it unchecked for a descending sort.

Report Preview Tab

You can use the Report Preview tab both to preview the output of a report and to troubleshoot problematic reports. For example, if you create a row in the Selection tab that tries to compare two fields of different types, the Report Preview tab shows the SQL query generated based on the Report Definition and helps you to find the problem.

Security Tab

The privileges available in the Security tab are as follows.

Privilege Description
Report.Create Create reports
Report.Delete Delete reports
Report.Edit Edit reports
Report.View Access reports