Previous Topic: Rolenames

Next Topic: Methods for Adding a View to a Model


Views

In a physical model, you can create a view, which is a SQL query that is permanently stored in the database under assigned names. Typically, a view is used to present specific database information for a target audience. In the following example, the accounting department of a video store chain presumably uses the CUSTOMER INVOICE view to generate a billing invoice.

A view is really a virtual table; a view table (box) and relationship line are both drawn with dashed-lines.

In the physical model, you can use view tools in the toolbox to draw the view table and connect the view relationship to a source table. Behind the scenes, the SQL query is written for the view, which you can view and edit in the View Editor.

You can use views in SQL to perform the following tasks: