| Help : Reports : Templates : Parameters |
The following table list the actions and arguments recognized in a report template:
| Action | Arguments | Description |
|---|---|---|
| action=include | file | Process specified template file and insert results. |
| action=set | Set the specified <key>=<value>
pairs so that they can be used as default values in subsequent commands in
this document.
Note: Subsequent commands can also refer named variables defined
by a set action. The syntax used for this type of reference is
$<key>. For example, the statements: |
|
| action=clear | Clear the values assigned by set actions. | |
| action=print | variable | Insert the value assigned to the specified
variable. e.g. variable=valueColumn will print the value of the valueColumn variable. |
| action=ask | askCategory | Prompt for parameters and their values. Once values have been
obtained the ask block is converted into a set block with the supplied values.
Note: The ask action can only be used in Interactive Reports. |
| askName | ||
| askDescription | ||
| askTitle | ||
| <param>.<attr> | ||
| action=date | date | Print the date range in the specified format. |
| TZ | ||
| format | ||
| action=index | category | Create an index entry for this report in the Scheduled Reports list. The reports will be grouped by category, and listed by their names and descriptions. |
| name | ||
| description | ||
| action=toc | category | Create a table of contents listing all the
reports by their index entries. If category is omitted, all reports will
be listed. If specified, only reports in the specified category will be
listed. Note: Typically the toc action will only be used in the index.shtml template, since this template is guaranteed to be evaluated last. If the toc action is used in other templates it will result in an incomplete listing of reports, listing only those reports that have already been evaluated. |
| action=report | host | Insert a chart or table as specified by the parameters. |
| reportName | ||
| reportFormat | ||
| width | ||
| height | ||
| categoryColumn | ||
| valueColumn | ||
| includeLinks | ||
| includeDelta | ||
| chartType |
![]()
The category for this report on the Interactive Reports page.
![]()
The name of this report on the Interactive Reports page.
![]()
The description of this report on the Interactive Reports page.
![]()
The title of the form when prompting for parameters.
![]()
Prompt for a value for a parameter. Different attributes can be supplied:
| prompt The prompt string to be used when asking for the parameter. | |
| default The default value of the parameter. | |
| options A list of possible parameter values. Certain option lists are predefined and can be referred to by name. These include dateOptions, groupPeriodOptions and tableTypeOptions | |
| required Set to YES if a value must be supplied before the report can be evaluated. |
For example, the statements:
serverAddress.prompt=Server IP Address;
serverAddress.default=10.0.0.1;
serverAddress.options=10.0.0.1,10.0.0.2,10.0.0.3,10.0.0.4;
serverAddress.required=yes;
would result in the following request:
|
Server IP Address |
![]()
Only the following date values are permitted:
| today | |
| yesterday | |
| thisWeek | |
| lastWeek | |
| thisMonth | |
| lastMonth | |
| last24Hours | |
| last7Days | |
| last30Days |
![]()
The time zone to use when printing the date. See Parameter:TZ
![]()
Set the format for printing a time interval. Valid format values are:
| range Print the date interval as a range (e.g. [start - end]) | |
| start Print the start of the date range. | |
| end Print the end of the date range. |
![]()
The category for this report on the Scheduled Reports page.
![]()
The name of this report on the Scheduled Reports page.
![]()
The description of this report on the Scheduled Reports page.
![]()
The Traffic Server to which the Report query will be addressed. Default is localhost.
![]()
The following reports are defined:
![]()
The following formats are available:
| chart Insert a chart specified of type chartType | |
| table Insert results as an html table. |
![]()
The width of the chart gif in pixels.
![]()
The height of the chart gif in pixels.
![]()
The name of the attribute that will be used to create chart categories. For example, setting categoryColumn=sourceAddress will create a chart with a bar for each source address in the data.
categoryColumn names depend on the type of query generating the report data. The category column must be taken from the list of Key Fields:
| Site Traffic | |
| Site Service | |
| Events |
![]()
The name of the attribute that will be used to create chart values. For example, setting valueColumn=bytes will create a chart in which each bar represents the number of bytes.
valueColumn names depend on the type of query generating the report data. The value column must be taken from the list of Value Fields:
| Site Traffic | |
| Site Service | |
| Interface Counters |
![]()
The name of the attribute that will be used to create chart values. For example, setting valueColumn=bytes will create a chart in which each bar represents the number of bytes.
valueColumn names depend on the type of query generating the report data. The value column must be taken from the list of Value Fields:
![]()
If reportFormat is a table then setting includeDelta to YES creates an additional column in the table representing the delta between the current position in the table and the position the last reporting interval. The delta column contains the following symbols:
| A rise of M positions since the last report. | |
| A decline of N positions since the last report. | |
| Position unchanged. | |
| New in the list. |
![]()
The following chart types are supported:
| horizontalBar | |
| bar | |
| pie |