Skip to content

Instantly share code, notes, and snippets.

@riceissa
Created August 6, 2017 20:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save riceissa/d8b20da4543e1234c99da8715e1e474b to your computer and use it in GitHub Desktop.
Save riceissa/d8b20da4543e1234c99da8715e1e474b to your computer and use it in GitHub Desktop.
mysql> select count(distinct donee) as numDonees from donations where influencer is not NULL and cause_area REGEXP "AI risk";
+-----------+
| numDonees |
+-----------+
| 3 |
+-----------+
1 row in set (0.01 sec)
mysql> select count(distinct donee) as numDonees from donations where influencer is NULL and cause_area REGEXP "AI risk";
+-----------+
| numDonees |
+-----------+
| 9 |
+-----------+
1 row in set (0.03 sec)
mysql> select count(distinct donee) as numDonees from donations where cause_area REGEXP "AI risk";
+-----------+
| numDonees |
+-----------+
| 11 |
+-----------+
1 row in set (0.03 sec)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment