Read-only Back to SQLite3 Guide
Northwind › Views
Sales Totals by Amount view

66 rows. A view stores a SELECT statement, not rows: each time you open it, SQLite runs the query again.

Data Structure
Columns
PRAGMA table_info
#NameTypeNot nullDefaultKeyReferences
0 SaleAmount (none) no —
1 OrderID INTEGER no —
2 CompanyName TEXT no —
3 ShippedDate TEXT no —
Definition
from sqlite_schema
CREATE VIEW "Sales Totals by Amount" AS SELECT "Order Subtotals".Subtotal AS SaleAmount, Orders.OrderID, Customers.CompanyName, Orders.ShippedDate FROM Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID INNER JOIN "Order Subtotals" ON Orders.OrderID = "Order Subtotals".OrderID WHERE "Order Subtotals".Subtotal > 2500 AND Orders.ShippedDate BETWEEN '1997-01-01' AND '1997-12-31'