Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Parsing JSON in mysql 5.5

I have a string stored as json in a mysql table. I need to parse the string and return the value within a stored procedure.

Does Mysql 5.5 support this?

I came across this UDF: https://github.com/ChrisCinelli/mysql_json

Unfortunately, I cannot install this UDF on my mysql server due to operational issues.

How to parse json in mysql?

Note: We use percona version of MySQL

like image 563
ssk Avatar asked Sep 25 '22 03:09

ssk


1 Answers

I ended up using common_schema: https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/common-schema/common_schema-2.2.sql

It has json parsing function: https://common-schema.googlecode.com/svn/trunk/common_schema/doc/html/extract_json_value.html

like image 147
ssk Avatar answered Sep 28 '22 04:09

ssk