Section: Create reusable views

Query a view

sql
sql
SELECT * FROM recent_posts ORDER BY created_at DESC LIMIT 20;
Explanation

Useful for dashboards and administrative pages.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Create reusable views
Create a view
Define a reusable read-only query projection.
OpenIn sheetsqlsame section
Create an AFTER INSERT trigger
Write to an audit log when a row is created.
OpenIn sheetsql1 tag match
Touch updated_at from a trigger
Maintain a timestamp on row changes.
OpenIn sheetsql1 tag match
Normalize data with a generated column
Compute a lowercased email for indexing or search.
OpenIn sheetsql1 tag match
Index a generated column
Speed up queries over a derived value.
OpenIn sheetsql1 tag match