Issue querying a json value in laravel project
I’m trying to fetch a record from MSSQL table based on field value which contains json data. Following is the sample column value for ‘updated_value’ column: [[{“phone_number”:”5555555555″,”phone_type”:”H”,”inactive_date”:null,”restrictions”:[“SU”,”F”],”start_time”:null,”end_time”:null}]] My query is: $existing = ContactChangeLogs::latest() ->where(‘updated_value->phone_number’, ‘5555555555’) ->first(); But dd($existing) gives null result. the updated_value is an array of array so try to do updated_value[0]->phone_number – [SQL … Read more