Databases

View

A named query stored in the database that behaves like a virtual table - it does not hold data itself but runs its defining query each time it is read.

Views simplify access by hiding complex joins behind a table-like interface, and they can enforce row-level security by filtering what a role sees. Materialised views (PostgreSQL, Oracle) store the result physically for faster reads but must be refreshed when the underlying data changes. In PostgreSQL, a simple view is updatable if it meets certain conditions; otherwise writes require an INSTEAD OF trigger or rule.

Implemented by

Related concepts