Web System Views are SQL queries (see Web System SQL Queries) saved in the databse. They can be used in other queries, along with tables (unlike queries, views are database objects). It is not uncommon to create views based on other views.
Creating views is one of the key aspects of quality database design. Views encapsulate the details of table structures, which may change during the development process.
A View in Younicycle is created by selecting a specific Query(seeWeb System SQL Queries).
Name - Name of the future View. The name of the View cannot be the same as the names of tables or any other Views in the database (regardless of the folder in which they are saved). This limitation is based on a PostgreSQL requirement.
Description - View description. Information field for database developers.
Folder - Folder in which a View will be saved.
Select query - select a query, the basis on which a View is created.
When you click the View tab, you will see the output of the View and the Dependency for that View. You can move (reorganize) your View to a different folder from this tab.
View cpu_i7_8 is part of FROM clause just like regular tables. You may find it helful to name your Views with 'v_' to aid in identifying Views as opposed to Tables. 'v_cpu_i7_8', as an example.
Your list of Views will appear in the Dataset Design tab of the Query Builder - below your list of Tables.
A View is treated by PostgreSQL as a type of Temporary Table.
Shown below is the SQL Tab of the Query Builder, for a specific Query - which includes a View.
You can always Test your Query by clicking the Refresh button in the Test Query Tab of the Query Builder.
You can test before you save, allowing immediate feedback.
As with Tables, you can Export the data from a View as CSV, XML or Excel by clicking the Export tab. Shown below is the Export interface.
File type - Picks the file type data would be exported to: CSV (comma separated values), XML, or MS Excel table.
Separate character - Column separator. Available only when exporting to CSV.
Fields order - Sets the column order in the exported file.
Note: "file" columns can't be exported.