1
0
mirror of https://github.com/lana-k/sqliteviz.git synced 2025-12-06 18:18:53 +08:00

Add headers; fix images and links

This commit is contained in:
lana-k
2022-01-06 22:34:07 +01:00
parent 0698522fa5
commit 27bb23ac3d
10 changed files with 51 additions and 86 deletions

View File

@@ -1,7 +1,9 @@
# How to build a pivot table in SQLite
This how-to explores how to build pivot tables in SQLite, which doesn't have a
special constructs like `PIVOT` or `CROSSTAB` in its SQL dialect.
# Static-column pivot table
## Static-column pivot table
If the columns of a pivot table are known beforehand, it's possible to write a
standard, say SQL-92, query that would produce a pivot table in its result set.
@@ -87,7 +89,7 @@ ORDER BY
END
```
# Dynamic-column pivot table
## Dynamic-column pivot table
SQLite in sqliteviz is built with [pivot_vtab][2] extension. The same result set
can be produced with this, arguably simpler and more maintainable, query.