Passing Parameters

The following table provides a list of tags that define all of the available parameters that can be passed to a Report.

The integer value of these tags is derived from the corresponding parameter list. When defining a tag within the Report you must ensure that the corresponding parameter drop-down list is enabled.

To enable the desired parameter(s), enter "true" between the <></> tags; the below example enables the primary key/category parameter to be specified:
<Key1>true</Key1>

The second column of parameters is used to display the corresponding text value for the parameter in the Report output.

Team [PARAM1] [PARAMTEXT1]
Skill Group [PARAM2] [PARAMTEXT2]
User [PARAM3] [PARAMTEXT3]
Call Type [PARAM4] [PARAMTEXT4]
Status [PARAM5] [PARAMTEXT5]
Received By [PARAM6] [PARAMTEXT6]
Urgency [PARAM7] [PARAMTEXT7]
Product Type [PARAM8] [PARAMTEXT8]
Risk [PARAM9] [PARAMTEXT9]
Product [PARAM10] [PARAMTEXT10]
Priority [PARAM11] [PARAMTEXT11]
Impact [PARAM12] [PARAMTEXT12]
Key 1 [PARAM13] [PARAMTEXT13]
Service Area [PARAM14] [PARAMTEXT14]
Key 2 [PARAM15] [PARAMTEXT15]
Symptom Code [PARAM16] [PARAMTEXT16]
Key 3 [PARAM17] [PARAMTEXT17]
Cause Code [PARAM18] [PARAMTEXT18]

Other parameters that can be used in the Reports are listed below.

[FREETEXT1] Gets replaced with the content of the 'Free Text' field available on the Report Details tab
[SYSUSERID] Gets replaced with the ID of the current system user
[SYSUSEREMAIL] Gets replaced with the email address of the current system user
[BASEURL] Gets replaced with the Global Settings versaSRSURL
[STARTDATE1] Gets replaced with the 'Start Date' selection in the Report Details tab
[ENDDATE1] Gets replaced with the 'End Date' selection in the Report Details tab
[NOW] Gets replaced with the current date and time
[TODAY] Gets replaced with the current date
[QPARAM1] to [QPARAMX] Gets replaced by the output of the ParametersQuery, where X is the number of parameters available from the query
[DATA1] to [DATAX] Gets replaced with the column value from the Query where X is the number of columns returned in the Query
[SYSLABELX] Gets replaced by the versaSRS System Labels, where X is the number of the required System Label

Case status labels that can be used in the Report are listed below.

New [SYSCALLSTATUSLABEL1]
Open [SYSCALLSTATUSLABEL2]
Closed [SYSCALLSTATUSLABEL3]
Pending [SYSCALLSTATUSLABEL4]
Stalled [SYSCALLSTATUSLABEL5]
Cancelled [SYSCALLSTATUSLABEL6]
Re-Opened [SYSCALLSTATUSLABEL7]
Dormant [SYSCALLSTATUSLABEL8]
Archived [SYSCALLSTATUSLABEL9]

Task status system labels that can be used in the Report are listed below.

Completed [SYSTASKSTATUSLABEL1]
Delayed [SYSTASKSTATUSLABEL2]
In Progress [SYSTASKSTATUSLABEL3]
Not Commenced [SYSTASKSTATUSLABEL4]
Pending [SYSTASKSTATUSLABEL5]
Problems [SYSTASKSTATUSLABEL6]
Superseded [SYSTASKSTATUSLABEL7]
Archived [SYSTASKSTATUSLABEL8]
Dormant [SYSTASKSTATUSLABEL9]
Rejected [SYSTASKSTATUSLABEL10]
ReWork [SYSTASKSTATUSLABEL11]

Problem status labels that can be used in the Report are listed below.

New [SYSPROBLEMSTATUSLABEL1]
Open [SYSPROBLEMSTATUSLABEL2]
Closed [SYSPROBLEMSTATUSLABEL3]
Pending [SYSPROBLEMSTATUSLABEL4]
Stalled [SYSPROBLEMSTATUSLABEL5]
Cancelled [SYSPROBLEMSTATUSLABEL6]
Re-Opened [SYSPROBLEMSTATUSLABEL7]
Dormant [SYSPROBLEMSTATUSLABEL8]
Archived [SYSPROBLEMSTATUSLABEL9]

RFC status labels that can be used in the Report are listed below.

New [SYSCHANGEREQUESTSTATUSLABEL1]
Open [SYSCHANGEREQUESTSTATUSLABEL2]
Closed [SYSCHANGEREQUESTSTATUSLABEL3]
Pending [SYSCHANGEREQUESTSTATUSLABEL4]
Stalled [SYSCHANGEREQUESTSTATUSLABEL5]
Cancelled [SYSCHANGEREQUESTSTATUSLABEL6]
Re-Opened [SYSCHANGEREQUESTSTATUSLABEL7]
Dormant [SYSCHANGEREQUESTSTATUSLABEL8]
Archived [SYSCHANGEREQUESTSTATUSLABEL9]

Example: This example shows how to construct a Report showing the Current Cases for a User specified Team.

Sample Code <Reporting> <ReportTitle>Current Cases For Help Desk Team</ReportTitle> <ReportHeader></ReportHeader> <ReportFooter></ReportFooter> <Parameters> <StartDate1>true</StartDate1> <EndDate1>true</EndDate1> <Queue>true</Queue> <SkillGroup>false</SkillGroup> <User>false</User> <CallType>false</CallType> <CallStatus>false</CallStatus> <ReceivedBy>false</ReceivedBy> <Urgency>false</Urgency> <ProductType>false</ProductType> <Risk>false</Risk> <Product>false</Product> <Priority>false</Priority> <Impact>false</Impact> <Key1>false</Key1> <Key2>false</Key2> <Key3>false</Key3> <ServiceArea>false</ServiceArea> <SymptomCode>false</SymptomCode> <CauseCode>false</CauseCode> </Parameters> <Report> <Title>Current Cases</Title> <Totals></Totals> <Query>SELECT CallID, Subject FROM tbl_Calls WHERE QueueID = [PARAM1] AND CallStatusID IN (1, 2, 4, 7) AND (DateEntered BETWEEN '[STARTDATE1] 00:00:00' AND '[ENDDATE1] 23:59:59') </Query> <Columns></Columns> </Report> </Reporting>

When the operator selects a Team from the available list, the unique QueueID is passed to the Report engine as [PARAM1]. The SQL syntax for the Report is then parsed and all instances of [PARAM1] are replaced with the selected QueueID.

Security: Non-Administrators, the operator will only be presented with a list of available Teams for which they are a member. System Administrators will be presented with all available Teams.

Parameters can also be passed within a URL Query String to directly run Reports via hyperlink. The example URL below will run Report ID -142 (Active Cases By Category) for the Team with ID = 2 for the last month worth of data.
NOTE: When passing parameters via URL there must be a value passed in for every parameter available.

https://[YOURSERVER]/reporting_dashboard.aspx?ReportID=-142&StartDate=THISMONTH-1&EndDate=THISMONTH&param1=2&param2=-1&param3=-1&param4=-1&param5=-1&param6=-1&param7=-1&param8=-1&param9=-1&param10=-1&param11=-1&param12=-1&param13=-1&param14=-1&param15=-1&param16=-1&param17=-1&param18=-1

The below table shows the parameter tags that can be used in the URL Query String.

Team param1
Skill Group param2
User param3
Call Type param4
Status param5
Received By param6
Urgency param7
Product Type param8
Risk param9
Product param10
Priority param11
Impact param12
Key 1 param13
Service Area param14
Key 2 param15
Symptom Code param16
Key 3 param17
Cause Code param18
Free Text freetext
Start Date startdate
End Date enddate

Specifying the date range within the query string is done by entering a valid combination of the below date parameters that will set the startdate and enddate of the Report.


For example setting a startdate of THISYEAR - 3 and an enddate of THISDAY will set the date range to be January 1st 12:00am 3 years prior to the current date and time.

https://[YOURSERVER]/reporting_dashboard.aspx?ReportID=-142&StartDate=THISYEAR-3&EndDate=THISDAY&param1=2


Setting a startdate of THISYEAR and an enddate of THISYEAR will set the range to be January 1st 12:00am until December 31st 11:59pm.

https://[YOURSERVER]/reporting_dashboard.aspx?ReportID=-142&StartDate=THISYEAR&EndDate=THISYEAR&param1=2

Date Parameters:
THISYEAR
THISMONTH
THISWEEK
THISDAY
TODAY
Or
THISYEAR-n Where n is a number
THISMONTH-n Where n is a number
THISWEEK-n Where n is a number
THISDAY-n Where n is a number
TODAY-n Where n is a number
Or
LASTYEAR
LASTMONTH
LASTWEEK
YESTERDAY