I use codeigniter. i have following values as json_encode in database row, i want delete value 3
in row 1 and values 14
& 5
in database table.
DELETE -> value 3
on row 1 & values 14
, 5
on rows 2
UPDATE -> value 2
to 8
on row 1 & value 3
to 17
on rows 2.
How is query it for values json?
Row 1:
id=1
[{
"hotel_id": ["3"]
}, {
"hotel_id": ["2"]
}, {
"hotel_id": ["1"]
}]
Row 2:
id=2
[{
"hotel_id": ["14"]
}, {
"hotel_id": ["5"]
}, {
"hotel_id": ["4"]
}, {
"hotel_id": ["3"]
}, {
"hotel_id": ["2"]
}, {
"hotel_id": ["1"]
}]
See Question&Answers more detail:os