How to extract JSON from MySQL Database

When you try to fetch JSON data from your MySQL like below with a SQL query, you might get Error : Unimplemented MAX_NO_FIELD_TYPES.

select JSON_EXTRACT(sample,'$[0].os') from test

If this is the case you can CAST your function like below to workaround it.

select CAST(JSON_EXTRACT(sample,'$[0].os') as CHAR) from test