Reverse query with similar - laravel eloquent or raw MySQL query
I have a table with user submitted links. Some links do not contain
`http://`
I want to list these records using the following query:
$object = Related::whereHas( function($q)
{
$q->where('URL', 'like', 'http%');
})->get();
How do I cancel a request to receive them?
thank
+3
Peter
source
to share
1 answer
You can probably use the operator not like
in this case:
$object = Related::whereHas( function($q)
{
$q->where('URL', 'not like', 'http%');
)->get();
+10
Marcin Nabiałek
source
to share