Thunderbird/Support/Google Big Query Sample SQL queries: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
(→‎2025-08-18 queries have changed to project 'sumo-prod', folder 'moz-fx-sumo-prod' and dataset is SUMO: someday soon moz-fx-data-sumo-prod will be deleted and old queries will stop working)
(fix typos)
Line 1: Line 1:
__TOC__
__TOC__
== 2025-08-18 queries have changed to project 'sumo-prod', folder 'moz-fx-sumo-prod' and dataset is SUMO==
== 2025-08-18 queries have changed to project 'sumo-prod', folder 'moz-fx-sumo-prod' and dataset is SUMO==
* The pre August 18, 2025m queries on the rest of this page will no longer work when <code>moz-fx-data-sumo-prod</code> is deleted therefore :-)
* The pre August 18, 2025 queries on the rest of this page will no longer work when <code>moz-fx-data-sumo-prod</code> is deleted therefore :-)
* They will work if you change the project (top left corner of the screen) to <code>sumo-prod</code> and the folder to <code>moz-fx-sumo-prod</code> and the table to <code>sumo.metrics_thunderbird_questions</code> <-- This is left as an exercise for the reader :-)
* They will work if you change the project (top left corner of the screen) to <code>sumo-prod</code> and the folder to <code>moz-fx-sumo-prod</code> and the table to <code>sumo.metrics_thunderbird_questions</code> <-- This is left as an exercise for the reader :-)



Revision as of 16:00, 28 August 2025

2025-08-18 queries have changed to project 'sumo-prod', folder 'moz-fx-sumo-prod' and dataset is SUMO

  • The pre August 18, 2025 queries on the rest of this page will no longer work when moz-fx-data-sumo-prod is deleted therefore :-)
  • They will work if you change the project (top left corner of the screen) to sumo-prod and the folder to moz-fx-sumo-prod and the table to sumo.metrics_thunderbird_questions <-- This is left as an exercise for the reader :-)

Working query

SELECT *  FROM `sumo.metrics_thunderbird_questions` LIMIT 1000

Count All Solved Android Desktop Questions in 2024

tb_android_2024_aaq,solved_tb_android_2024
311,12
SELECT
  COUNT(*) as tb_android_2024_aaq, COUNTIF(is_solved is true) AS solved_tb_android_2024
FROM
  moz-fx-data-sumo-prod.mzla.metrics_thunderbird_questions
WHERE
  EXTRACT(YEAR
  FROM
    DATETIME(created_utc)) = 2024
  AND product LIKE 'thunderbird-android'
;

Count All Solved Thunderbird Desktop Questions in 2024

tb_desktop_2024_aaq,solved_tb_desktop_2024
15506,1970
SELECT
  COUNT(*) as tb_desktop_2024_aaq, COUNTIF(is_solved is true) AS solved_tb_desktop_2024
FROM
  moz-fx-data-sumo-prod.mzla.metrics_thunderbird_questions
WHERE
  EXTRACT(YEAR
  FROM
    DATETIME(created_utc)) = 2024
  AND product LIKE 'thunderbird'
;

Count All Thunderbird Desktop Questions in 2024

SELECT
  COUNT (*)
FROM
  moz-fx-data-sumo-prod.mzla.metrics_thunderbird_questions
WHERE
  EXTRACT(YEAR
  FROM
    DATETIME(created_utc)) = 2024
  AND product LIKE 'thunderbird'
;