mysql-5.7-json函数使用与常用函数

这篇博客介绍了在MySQL 5.7中如何使用JSON数据类型和相关函数,包括创建、插入、查询和修改JSON字段。内容涵盖JSON列的创建、JSON对象和数组的更新、JSON_EXTRACT和JSON_SEARCH等查询方法,以及JSON_ARRAY_APPEND和JSON_REMOVE等操作。
摘要由CSDN通过智能技术生成

今天是2019年的第一天。

在项目中遇到了关于mysql中对json字段进行处理的问题,顺便进行了学习。

项目demo:

--需要处理的json 字段
json:
{
    "6A90F6607C06084FE053201E12AC9004": {
        "sign": "1",
        "prodPzwh": "J20170028",
        "prodZczh": "H20170193",
        "pzwhAttach": [{
            "attachUrl": "reviseAttach/ciNXiCZ3P51537345506305.edc",
            "attachName": "ciNXiCZ3P51537345506305.edc",
            "attachSize": 354214,
            "attachType": "application/octet-stream",
            "oAttachName": "1.1吉泰瑞40 - 注册证批件 - 国药准字J20170028.edc"
        }],
        "zczhAttach": [{
            "attachUrl": "reviseAttach/8nRMXikTEY1537345509939.edc",
            "attachName": "8nRMXikTEY1537345509939.edc",
            "attachSize": 354214,
            "attachType": "application/octet-stream",
            "oAttachName": "1.1吉泰瑞40 - 注册证批件 - 国药准字J20170028.edc"
        }],
        "auditResult": {
            "auditOption": "",
            "auditStatus": ""
        },
        "auditResults": [],
        "prodPlaceCode": "F",
        "pzwhValidityEnd": "2022-02-20",
        "zczhValidityEnd": "2022-02-20",
        "pzwhValidityStart": "2017-04-24",
        "zczhValidityStart": "2017-04-01",
        "pzwhValidityStart,pzwhValidityEnd": "",
        "zczhValidityStart,zczhValidityEnd": ""
    },
    "6A90F6607C07084FE053201E12AC9004": {
        "sign": "1",
        "attachJsons": [{
            "attachUrl": "reviseAttach/nxtFEhyh6D1537345528512.edc",
            "attachName": "nxtFEhyh6D1537345528512.edc",
            "attachSize": 863593,
            "attachType": "application/octet-stream",
            "oAttachName": "6.吉泰瑞40mg-说明书包装20170424.edc"
        }],
        "auditResult": {
            "auditOption": "",
            "auditStatus": ""
        },
        "auditResults": []
    },
    "6A90F6607C0A084FE053201E12AC9004": {
        "sign": "1",
        "auditResult": {
            "auditOption": "",
            "auditStatus": ""
        },
        "auditResults": [],
        "prodSpeAttach": [{
            "attachUrl": "reviseAttach/EXnzcyt7nF1537345551645.edc",
            "attachName": "EXnzcyt7nF1537345551645.edc",
            "attachSize": 240180,
            "attachType": "application/octet-stream",
            "oAttachName": "外包装.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值