{"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853554550", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853554550, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU1NDU1MA==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:34:38Z", "updated_at": "2021-06-03T04:34:38Z", "author_association": "OWNER", "body": "Documentation: https://sqlite-utils.datasette.io/en/latest/cli.html#listing-indexes", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853548442", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853548442, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU0ODQ0Mg==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:16:49Z", "updated_at": "2021-06-03T04:16:49Z", "author_association": "OWNER", "body": "Needs to show the table each index applies to.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853547681", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853547681, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU0NzY4MQ==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:14:28Z", "updated_at": "2021-06-03T04:14:28Z", "author_association": "OWNER", "body": "This looks good:\r\n```\r\n% sqlite-utils indexes /tmp/covid.db -t \r\nindex_name seqno cid name desc coll key\r\n------------------------------------------------------ ------- ----- ----------------- ------ ------ -----\r\nidx_johns_hopkins_csse_daily_reports_combined_key 0 12 combined_key 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_country_or_region 0 1 country_or_region 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_province_or_state 0 2 province_or_state 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_day 0 0 day 0 BINARY 1\r\nidx_ny_times_us_counties_date 0 0 date 1 BINARY 1\r\nidx_ny_times_us_counties_fips 0 3 fips 0 BINARY 1\r\nidx_ny_times_us_counties_county 0 1 county 0 BINARY 1\r\nidx_ny_times_us_counties_state 0 2 state 0 BINARY 1\r\n\r\n% sqlite-utils indexes /tmp/covid.db -t --aux\r\nindex_name seqno cid name desc coll key\r\n------------------------------------------------------ ------- ----- ----------------- ------ ------ -----\r\nidx_johns_hopkins_csse_daily_reports_combined_key 0 12 combined_key 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_combined_key 1 -1 0 BINARY 0\r\nidx_johns_hopkins_csse_daily_reports_country_or_region 0 1 country_or_region 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_country_or_region 1 -1 0 BINARY 0\r\nidx_johns_hopkins_csse_daily_reports_province_or_state 0 2 province_or_state 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_province_or_state 1 -1 0 BINARY 0\r\nidx_johns_hopkins_csse_daily_reports_day 0 0 day 0 BINARY 1\r\nidx_johns_hopkins_csse_daily_reports_day 1 -1 0 BINARY 0\r\nidx_ny_times_us_counties_date 0 0 date 1 BINARY 1\r\nidx_ny_times_us_counties_date 1 -1 0 BINARY 0\r\nidx_ny_times_us_counties_fips 0 3 fips 0 BINARY 1\r\nidx_ny_times_us_counties_fips 1 -1 0 BINARY 0\r\nidx_ny_times_us_counties_county 0 1 county 0 BINARY 1\r\nidx_ny_times_us_counties_county 1 -1 0 BINARY 0\r\nidx_ny_times_us_counties_state 0 2 state 0 BINARY 1\r\nidx_ny_times_us_counties_state 1 -1 0 BINARY 0\r\n```", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853546818", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853546818, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU0NjgxOA==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:11:46Z", "updated_at": "2021-06-03T04:11:46Z", "author_association": "OWNER", "body": "By default I won't return auxiliary columns, but I'll offer a `--aux` option to return them.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853545743", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853545743, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU0NTc0Mw==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:08:04Z", "updated_at": "2021-06-03T04:08:04Z", "author_association": "OWNER", "body": "Figuring out the right queries:\r\n\r\nhttps://covid-19.datasettes.com/covid?sql=select+sqlite_master.name%2C+i.*+from+sqlite_master%0D%0Ajoin+pragma_index_list%28sqlite_master.name%29+i%0D%0Awhere+type+%3D+%27table%27\r\n\r\nThis query shows all columns across all indexes across all tables:\r\n\r\n```sql\r\nselect i.name as index_name, xinfo.* from sqlite_master\r\njoin pragma_index_list(sqlite_master.name) i\r\njoin pragma_index_xinfo(index_name) xinfo\r\nwhere sqlite_master.type = 'table'\r\n```\r\nhttps://covid-19.datasettes.com/covid?sql=select+i.name+as+index_name%2C+xinfo.*+from+sqlite_master%0D%0Ajoin+pragma_index_list%28sqlite_master.name%29+i%0D%0Ajoin+pragma_index_xinfo%28index_name%29+xinfo%0D%0Awhere+sqlite_master.type+%3D+%27table%27", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null} {"html_url": "https://github.com/simonw/sqlite-utils/issues/263#issuecomment-853544493", "issue_url": "https://api.github.com/repos/simonw/sqlite-utils/issues/263", "id": 853544493, "node_id": "MDEyOklzc3VlQ29tbWVudDg1MzU0NDQ5Mw==", "user": {"value": 9599, "label": "simonw"}, "created_at": "2021-06-03T04:03:59Z", "updated_at": "2021-06-03T04:03:59Z", "author_association": "OWNER", "body": "Here's how `sqlite-utils triggers` works: https://github.com/simonw/sqlite-utils/blob/9c67cb925253cd5ef54a1fe0496e0ff9caeacfd6/sqlite_utils/cli.py#L1266-L1277\r\n\r\nRunning it from a SQL query makes it easy to support modifiers like `--csv` and `-t`.", "reactions": "{\"total_count\": 0, \"+1\": 0, \"-1\": 0, \"laugh\": 0, \"hooray\": 0, \"confused\": 0, \"heart\": 0, \"rocket\": 0, \"eyes\": 0}", "issue": {"value": 906356331, "label": "`sqlite-utils indexes` command"}, "performed_via_github_app": null}