The Mysql version is 8.0.18-commercial
I have written the following query which displays results from details
column
select details from table t1;
Output:
[
{
"Msg": "Job Running",
"Task": "IN_PROGRESS",
"Date": "2020-07-20 16:25:15",
},
{
"Msg": "Job failed",
"Task": "IN_PROGRESS",
"Date": "2020-07-20 16:35:24",
}
]
I want the Msg
value only from the last element which has latest Date
My desired output is displaying Msg
of the element with latest date
:
ColumnName ColumnValue
Msg Job failed
I have written following query but it is giving null
output
select details->>"$.Msg" from table t1;