title: SQL big query script issue
body: <p>could you help me, I don't understand whats wrong with my WHERE. I tried several things but couldn't end to the right conclusion.</p>
  <pre><code>SELECT 
  CONCAT(fullvisitorId, &quot;-&quot;, CAST(visitstarttime AS STRING)) as session,
  RANK() OVER(PARTITION BY CONCAT(fullvisitorId, &quot;-&quot;, CAST(visitstarttime AS STRING)) ORDER BY hitNumber ASC) AS Rank, 
  (SELECT MAX(cd.value) FROM hits.customDimensions as cd where cd.index = 12) as cd1,
  (SELECT cd.value FROM hits.customDimensions as cd where cd.index=29) as division,
  hits.hitnumber
  
  FROM 
    `dl-training-bigquery.NDA_CHAN*******51.ga_sessions_20191202` as session,
    unnest(hits) as hits
    
  WHERE division = 'fsh'
  ORDER BY hitnumber ASC
  </code></pre>
  <p><a href="https://i.stack.imgur.com/QWTwv.png" rel="nofollow noreferrer">enter image description here</a></p>