Предположим, у меня есть схема, как один, упомянутых в BigQuery документации:BigQuery SQL IF над повторной записи
Last modified Schema Total Rows Total Bytes Expiration
----------------- ----------------------------------- ------------ ------------- ------------
27 Sep 10:01:06 |- kind: string 4 794
|- fullName: string (required)
|- age: integer
|- gender: string
+- phoneNumber: record
| |- areaCode: integer
| |- number: integer
+- children: record (repeated)
| |- name: string
| |- gender: string
| |- age: integer
+- citiesLived: record (repeated)
| |- place: string
| +- yearsLived: integer (repeated)
Предположим, что мы имеем fullNames: Джон, Josh, Гарри
citiesLived: NewYork, ЧИКАГО, Сиэттл
Как перебирать по городам, а также считать с помощью условных обозначений. Например, я хотел бы подсчитать, сколько пользователей с fullName = John проживали в обоих городахLived.place = newyork и citiesLived.place = chicago, но не жили в городахLived.place = seattle.
Спасибо, Джон