software:mysq:pivots
Differences
This shows you the differences between two versions of the page.
Last revisionBoth sides next revision | |||
software:mysq:pivots [2020/11/12 07:34] – created rodolico | software:mysq:pivots [2020/11/12 07:37] – rodolico | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Create a pivot result in mariadb/ | ====== Create a pivot result in mariadb/ | ||
- | This relies heavily on [[https:// | + | This relies heavily on [[https:// |
- | A pivot query (aka crosstab) is a type of query where the top, where you normally have column names, is the result of the query. Take this data structure (stolen from Taryn' | + | A pivot query (aka crosstab) is a type of query where the top, where you normally have column names, is the result of the query. |
+ | |||
+ | Take this data structure (stolen from Taryn' | ||
<code sql create_test.sql> | <code sql create_test.sql> | ||
Line 36: | Line 38: | ||
</ | </ | ||
- | A simple query to find everyone' | + | A simple query to find everyone' |
<code sql> | <code sql> |