Create Source Views
Create source views as a base for model objects when you think you might want to perform subsequent changes.
Topics:
About Source Views
Source views are saved queries of data in the database. You can think of a source view as a "virtual table."
You create source views when using a single table as a source for more than one dimension table. For example, you can create source views that use the Employee source table as a source for the Employee and Manager dimension tables.
You also create source views when creating a dimension table that is based on multiple source tables, as in a snowflake source. For example, you can create a source view that combines columns from the Customer and Customer Group source tables to create a single Customers dimension table.
You can also perform pre-aggregation calculations in a source view. For example, to create an Average Revenue column that is calculated pre-aggregation, you can include the calculation in the SQL query for the view:
SELECT "BICS_REVENUE_FT1"."UNITS", "BICS_REVENUE_FT1"."ORDER_KEY", "BICS_REVENUE_FT1"."REVENUE", "BICS_REVENUE_FT1"."PROD_KEY", "BICS_REVENUE_FT1"."REVENUE"/"BICS_REVENUE_FT1"."UNITS" AS AVERAGE_REVENUE FROM "BICS_REVENUE_FT1"
In general, create source views as a base for model objects when you think you might want to perform subsequent changes. Creating a semantic model based on source views provides greater flexibility than using source tables directly. For example, using source views makes it much easier to extend model objects, create filters, and add pre-aggregation calculations.
Add Your Own Source Views
You can add views to the source database from Data Modeler. For example, you can create a source view that combines the Brands and Products source tables to create a single source for your dimension table.
Create source views as a base for model objects when you think you might want to perform subsequent changes. You can create a view from scratch and add any column you want from other tables and views in the database. Alternatively, you can create a view by copying an existing source table or another source view.