From the course: PostgreSQL Essential Training

Unlock the full course today

Join today to access over 24,400 courses taught by industry experts.

Save a query as a database view

Save a query as a database view - PostgreSQL Tutorial

From the course: PostgreSQL Essential Training

Save a query as a database view

- [Instructor] Queries that join multiple tables together provide a useful way to review the data that's in your database. They allow you to see all of the related details in one data output grid no matter what table the columns are actually stored in. If this is useful, you probably want to be able to get back to this arrangement easily. One way is to save the text of your query in an external file. Then you can open it up in a new query editor, paste in the text, and execute it again. A better way is to save the query as a database view. Views get stored in the database and allow you to quickly get back to the same look at your data. I'm starting with the same query that we wrote in the last movie, but I've removed the where clause that filtered the final results. This query shows the 29 products and includes the related information from the categories table. In order to save this into the database I'll place my…

Contents