Report Configuration

Naming convention

We recommend that all reports saved to the report server follow the naming convention template below to provide clarity of what the report is, and where it’s being used within the user experience.

[INACTIVE] – [Form Definition] – [Report Title]

INACTIVE – This is optional. The inactive tag should only be applied if the report is currently not in use within the user experience, otherwise it’s not included.

Form Definition – This is the name of the form definition the report is being used on within the user experience.

Report Title – This is the title of the report, this should match the header title within the report itself.

Examples:

1. INACTIVE – Client – Closed Changes

2. Customer – Open Problems

Additionally, it’s important to add a description to the report to provide additional context explaining what is being reported for future developers who might need to update the report.

You can name and add a description to a report when you first create a new report.

Telerik report configuration

The following procedures do not cover how to create a Telerik Report from start to finish due to varying report requirements for each business. The procedures focus on what every report will need to function within trellispark. Existing reports can also be modified to work in trellispark.

If you’re brand new to Telerik Reports be sure to check out the First Steps Guide by Telerik which walks you through the creation process from start to finish. Simply add the requirements from this section to your report to make your new report compatible with trellispark.

Creating a stored procedure

Before creating and designing your report it’s best to first start by creating the TSQL stored procedure that the report will call to get data.

Use the TSQL template below as a starting point for your report.

In the template there are a few parts that need to be modified to work with your report.

  1. Rename the stored procedure – The name should be along the lines of RPT_FormDefinition_ReportName which follow the same convention noted in the Naming Convention section
CREATE PROCEDURE [dbo].[RPT_NameOfStoredProc]
  1. Update the error handling – Copy the new name you picked and replace the four (4) instances of RPT_NameOfStoredProc in the two error handling sections of the stored procedure
  2. Add the select statement for your report – Replace the line below with your select statement that will return the data for your report
-- Put your reports select statement here
  1. Update your parameters as required – All parameters shown are required and cannot be deleted, you may add additional parameters based on your report’s requirements
@SessionGUID AS UNIQUEIDENTIFIER
,@WorkspaceGUID AS UNIQUEIDENTIFIER
,@WorkspaceName AS VARCHAR(300)
,@UserGUID AS UNIQUEIDENTIFIER
,@UserName AS VARCHAR(300)
,@InstanceGUID AS UNIQUEIDENTIFIER
,@InstanceName AS VARCHAR(300)
,@InputString AS VARCHAR(MAX)
--Add any additional parameters that your report needs here

That’s all you need to create a stored procedure for a report that’s compatible with trellispark. Simply execute your stored procedure in the database you want to add it to.

Configure report

Inside the Telerik Report Designer open the report you want to configure to work in trellispark. There are three (3) things that need to be done for the report to be compatible with trellispark:

  • Report Parameters
  • Data Source Configuration
  • Publish Report

Report parameters

  1. In the Properties section of the report locate the ReportParameters property and select the button with the 3-dots.
Selecting the Report Parameters from the Properties section
  1. The ReportParameter Collection Editor dialog will appear. Add eight (8) default parameters that are required for every report used in trellispark.

IMPORTANT NOTE:

The parameters in the report should also match the parameters in the reports stored procedure. View the Creating a Stored Procedure section first if you haven’t created a stored procedure for this report yet.

  1. Each parameter must have name, type, value, and visible values set. To create a new parameter, select the Add button, then select the new parameter from the list. From there you can modify the parameter properties on the right. Once finished select the Ok button to close the dialog.
Adding the parameters to the report (inputs based on the table below)

Below is a list of all the default parameters you must create and the properties you must set for them:

Name

Type

Value

Visible

WorkspaceName

String

Server Owner

False

WorkspaceGUID

String

00000000-0000-0000-0000-000000000000

False

UserName

String

Test User

False

UserGUID

String

00000000-0000-0000-0000-000000000000

False

InstanceName

String

Test Report

False

InstanceGUID

String

00000000-0000-0000-0000-000000000000

False

SessionGUID

String

00000000-0000-0000-0000-000000000000

False

InputString

String

<None />

False

Data source configuration

Your SQL data source will need to be reconfigured to target the reports stored procedure and to link the report parameters with the stored procedures parameters.

Configure your SQL data source
  1. Start by right clicking your SQL data source and selecting Configure…
  2. The Configure SQL Data Source wizard will appear. On the first page we can select our data connection. Always use the correct Existing data connection. To seamlessly migrate reports across different environments (e.g., Dev, QA, Prod), do not build a new data connection with a connection string
  3. Once you’ve confirmed the correct data connection is used select Next at the bottom of the wizard
  4. On the next page we can configure our data source command. On this page you want to select the Stored Procedure option then use the dropdown list and select the stored procedure you want to use for this report. Go to Creating a Stored Procedure article if you have not created a stored procedure for your report yet
  5. If you don’t see your stored procedure listed, check that you’re using the correct existing data connection and have executed your stored procedure in the correct database
  6. Once your stored procedure has been selected, select Next at the bottom of the wizard
  7. On the next page, configure your data source parameters. Map your report parameters to your stored procedure parameters by updating the value field. Check the correct types are being used for each parameter
  8. Using the dropdown list in the DbType fields and in the Value fields, check their values match those in the screenshot below. Once finished, select Next
Verify the DbType and Value field inputs match
  1. On the Next page you can configure design time parameters. Set values for each parameter that will be used when you preview the report within the designer. These are not required and can be left blank for this demonstration. Once finished, select Next. Feel free to add values if you would like, just ensure they’re valid otherwise you won’t get any data results.
  2. On the next and final page of the wizard you can preview the data source results. This will always be blank unless you add valid values for each parameter on the previous page.
  3. Select Finish to complete the wizard.

Your data source is now setup and linked to your stored procedure!

Publish report

Once your report is finished it’s time to publish it to your report server. Once the report has been published to the report server, the trellispark report component will be able to read and display it.

To publish your report, select the Server tab at the top of the report designer, then select the Publish Button.

Select the server and publish your report

Your report is now published to your report server and can be read by the Report field component.

Previous article: Initial Setup

Updated on May 17, 2022

Article Attachments

Was this article helpful?

Related Articles

Need Support?
Can’t find the answer you’re looking for? Don’t worry we’re here to help!
Contact Support

Leave a Comment