mysql - MYSQL JSON Query with keys conditions
问题描述
I have a JSON column in a MYSQL table, I want to retrieve data from specific keys Where KEY is in an array of keys
For instance: My table name is functionalities This is my config column with JSON datatype:
{
"show_image":
{
"label": "Show Client Image",
"ui-elements": [".field-type-imagge"]
},
"view_balance":
{
"label": "View Client Balance",
"ui-elements": ["#profile-page-about-details"]
}
}
I want to select only the data for key name "show_image"
Something like this:
SELECT json_key FROM functionalities WHERE json_key IN ('show_image')
I'm USING MYSQL 5.7.22
How Can I do it?
Thanks
解决方案
推荐阅读
- paypal - 致命错误:未捕获的表“ramscoremod1.pss_paypal_login_user”不存在
- java - 我已经在谷歌控制台中启用了 PLACES API 并使用 SHA 密钥注册了我的应用程序,但我仍然收到错误以启用 Places Api
- c# - LINQ:在 GROUPBY AND SELECT 之后 WHERE 子句不起作用
- python - 在 Python 中生成统计表并导出到 Excel
- c# - 相机投球问题统一
- google-apps-script - 无法调用 null Google 电子表格的 getRange 方法
- android - 编码为 base64 密钥库文件
- php - PHP MYSQL 预处理语句 ORDER BY 问题
- google-cloud-platform - 通过 GCP 中的 API 应用大小调整建议
- javascript - 如何将 JavaScript 代码添加到 wordpress 中的 js 文件中