OiO.lk Blog SQL How to flatten a json array string in Redshift
SQL

How to flatten a json array string in Redshift


I have a table like this:

id       stage(varchar)
1        ["a","b"]
2        ["c"]

and I need to retrieve the data as the following format:

id       stage
1        a
1        b
2        c

How should I write my SQL in AWS Redshift?



You need to sign in to view this answers

Exit mobile version