From a9d138702c5b4d1d5d9402272b030c3c3d945593 Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Sun, 19 May 2019 14:19:35 -0700 Subject: [PATCH] Docs for facet-by-JSON-array, closes #477 --- docs/facets.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/facets.rst b/docs/facets.rst index 89ef391f..7d41bba1 100644 --- a/docs/facets.rst +++ b/docs/facets.rst @@ -128,3 +128,12 @@ The performance of facets can be greatly improved by adding indexes on the colum SQLite version 3.19.3 2017-06-27 16:48:08 Enter ".help" for usage hints. sqlite> CREATE INDEX Food_Trucks_state ON Food_Trucks("state"); + +Facet by JSON array +------------------- + +If your SQLite installation provides the ``json1`` extension (you can check using :ref:`JsonDataView_versions`) Datasette will automatically detect columns that contain JSON arrays of values and offer a faceting interface against those columns. + +This is useful for modelling things like tags without needing to break them out into a new table. + +You can try this functionality out at `latest.datasette.io/fixtures/facetable?_facet_array=tags `__ \ No newline at end of file