title: Getting flattened hit data from Google Analytics in Big Query over a range of tables
body: <p>The following is a query to flatten "hit" results piped to BigQuery from Google Analytics:</p>
  
  <pre><code>SELECT
  *
  FROM flatten(flatten(flatten(flatten(flatten(flatten(flatten(flatten(flatten([ga_sessions_20171116], hits), hits.product), hits.product.customDimensions), hits.product.customMetrics), hits.promotion), hits.experiment), hits.customDimensions), hits.customVariables), hits.customMetrics)
  Limit 20
  </code></pre>
  
  <p>How would one do the same across a range of tables, or is that even possible? I tried:</p>
  
  <pre><code>SELECT
  *
  FROM flatten(flatten(flatten(flatten(flatten(flatten(flatten(flatten(flatten([ga_sessions_2017111*], hits), hits.product), hits.product.customDimensions), hits.product.customMetrics), hits.promotion), hits.experiment), hits.customDimensions), hits.customVariables), hits.customMetrics)
  WHERE _TABLE_SUFFIX BETWEEN '0' and '10'
  Limit 20
  </code></pre>
  
  <p>But it didn't work. Does anyone know how one would do this?</p>