sql >> Base de Datos >  >> RDS >> Mysql

Cómo analizar JSON en el disparador MYSQL

Puede instalar common_schema . Entonces deberías poder hacer algo como esto:

select common_schema.extract_json_value(d.table1,'/multicast_id') as multicase_id,
common_schema.extract_json_value(d.table1,'/success') as success,
common_schema.extract_json_value(d.table1,'/failure') as failure,
common_schema.extract_json_value(d.table1,'/canonical_ids') as canonical_ids,
common_schema.extract_json_value(d.table1,'/results') as results,
common_schema.extract_json_value(d.table1,'/message_id') as message_id
from database d;