Lesson 3: Defining a Data Source View for Your Report Model
After defining the data sources that you will use in your report model project, your next step is to define a data source view for the project. A data source view is a logical data model based on one or more data sources. However, only data source views based on a single data source can be used for report models. Data source views not only encapsulate access to the physical objects, such as tables and views, contained in underlying data sources, but also allow additional annotations, such as definitions for named calculations, named queries, and relationships, to be created and managed outside the underlying data sources. Reporting Services generates the report model from the data source view. In this tutorial, the data source view provides the source information for the model you will generate.
Data source views facilitate the model design process by providing you with a useful representation of the data that you specified. Because metadata is stored in the data source view, you do not need to be connected to the underlying data source to work with the objects. You can rename tables, and fields, as well as add aggregate fields and derived tables, in a data source view without changing the underlying data source. For an efficient model, add only those tables to the data source view that you intend to use.
To define a data source view for a report model
In Solution Explorer, right-click Data Source Views and click Add New Data Source View.
On the Welcome To The Data Source View Wizard page, click Next.
The Select A Data Source page appears.
In the Relational Data Sources window, verify that the ModelTutorial data source is selected, and then click Next.
Only one data source can be referenced when creating a data source view for a model project. The Select Tables and Views page appears. On this page, you select the tables from the data source that you want to use in the data source view.
If the Name Matching page appears, accept the default selections and click Next.
In the Available Objects list, select all of the tables.
To add the selected tables to the Included Objects list, click >.
Click Next and then type ModelTutorial in the Name text box.
The ModelTutorial.dsv data source view appears in the Data Source Views folder in the ModelTutorial project. The View Designer window appears in Business Intelligence Development Studio displaying the contents of this data source view.
You have successfully created the ModelTutorial data source view containing the metadata for all of the tables from which you will define the initial version of the ModelTutorial project. Next, you will create a report model. See Lesson 4: Defining a Report Model.