Created
June 6, 2018 09:28
-
-
Save rmeekers/42a3c13d968e66e3810dca3735d06d7f to your computer and use it in GitHub Desktop.
Formula to import the number of internet users for a given country
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Datasource: public Google Spreadsheet with internet user data: | |
* https://docs.google.com/spreadsheets/d/1uxPf0einHJxZqkTvXnFto0O8Q4Lxw9RBPKoBCV2idTE/edit | |
* | |
* In the example below, we expect one or more country codes (ISO 3166-1 alpha-2), separated by a pipe (|), in cell A2 | |
*/ | |
= | |
SUM( | |
QUERY( | |
IMPORTRANGE("1uxPf0einHJxZqkTvXnFto0O8Q4Lxw9RBPKoBCV2idTE";"Data!B:C"); | |
"SELECT Col2 WHERE (Col1 matches '"&A2&"')" | |
) | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment