0

I'm using bigquery to search for patents that contain the word 'metal' in the title. My query: My query

Then I got the following error message: Error message

I checked the data structure for title_localized: The title_localized array

What I'm doing wrong?

Roman Pokrovskij
  • 9,449
  • 21
  • 87
  • 142
nay2Y
  • 11
  • 2
  • Welcome to Stackoverflow. Please refer https://stackoverflow.com/help/how-to-ask. Share the relevant code snippets you have tried so far. – Nagama Inamdar Feb 14 '19 at 08:55

1 Answers1

4

You can use UNNEST this way to query nested fields:

SELECT
  DISTINCT country_code
FROM
  `patents-public-data.patents.publications`,
  UNNEST(title_localized) AS t
WHERE
  t.text LIKE '%metal%'
Juta
  • 411
  • 1
  • 5
  • 12