count(distinct (case when … then … end))

SQLにおいて表題の件。自身はAthenaでとても重宝した。条件に合致した中での一意な数を取得したい。 ■ 環境 Amazon Athena ■ count(distinct) Athenaを利用しているので、読み込むデ … 続きを読む count(distinct (case when … then … end))