google sql scenario based interview questions and answers | sql interview questions and answers

Поділитися
Вставка
  • Опубліковано 7 вер 2024

КОМЕНТАРІ • 4

  • @dibyaranjanbasuri7331
    @dibyaranjanbasuri7331 Місяць тому

    I used the below way before looking at your solution:
    with cte as
    (select
    unnest(string_to_array(content, ' ')) as word
    from google_files)
    select word,count(word) as word_count
    from cte
    where word in ('SQL', 'PySpark')
    group by word
    Thanks for the solution, I learned 2 new functions.

  • @DataEngineerPratik
    @DataEngineerPratik Місяць тому

    could you please make alternate solution in mysql ?

  • @nikunjmistry373
    @nikunjmistry373 2 місяці тому

    In pg u can use unnest function along with json with a delimiter of a space to get the word together