SSRS Tutorial: Part 3 - Shared Datasets

Before reading this article, I highly recommend reading the previous parts of the series:

This article explains:

  • What are Datasets?
  • What are Shared Datasets?
  • How to add multiple Shared Datasets?
  • How to create Shared Dataset using Sql Query?
  • How to create Shared Dataset using Stored Procedure?

Dataset

  • Dataset represents report data that is returned from running a query on an external data source.

Shared Datasets

  • A shared dataset can be used by multiple reports.
  • A shared dataset must be based on a shared data source.
  • Shared datasets are stored on the report server.
  • A shared dataset can be cached and scheduled by creating a cache refresh plan.
  • Shared datasets can optimize a query result to benefit report performance.

Step 1: Create Shared Dataset (Using SQL Query).

Go to Solution Explorer and right click on Shared Datasets, and click on Add New Dataset.

Or

You can create by using expand Add, then click on New Item and select Dataset from the appeared wizard and give it to a desired name.

Add new dataset

Next the following wizard will appear.

  • Provide the name of dataset.
  • Here we will observe how shared datasets are based on a shared data source.
  • Select Query type as Text.
  • Write your query on Query text field and then click OK.

Dataset

At this point Shared Dataset created. You can see it in Solution Explorer.

Shared Dataset

Step 2: To add multiple Shared Datasets: (Using Stored Procedure)

Go to Solution Explorer and again right click on Shared Datasets, and click on Add New Dataset.
Next the following wizard will appear.

  • Provide the name of dataset.
  • Here we will observe how shared datasets are based on a shared data source.
  • Select Query type as Stored Procedure.
  • Write your query on Query text field and click OK.

Query

At this point, the second Shared Dataset created. You can see it in Solution Explorer.

Solution Explorer

I hope you enjoyed this article. Please provide your valuable suggestions and feedback.

X

Build smarter apps with Machine Learning, Bots, Cognitive Services - Start free.

Start Learning Now