Athena で 1フィールドの中の JSON の特定要素を型 CAST して抽出する方法



SELECT *,
         cast(json_extract(json_str,'$.val1') as integer) AS val1,
         cast(json_extract(json_str,'$.val2') as integer) AS val2
FROM "db"."table"