Merge pull request #164 from ArabCoders/dev
using LIKE for metadata/extra search in db:list
This commit is contained in:
@@ -205,7 +205,7 @@ final class ListCommand extends Command
|
||||
);
|
||||
}
|
||||
|
||||
$where[] = "json_extract(" . iFace::COLUMN_META_DATA . ",'$.{$sField}') = :jf_metadata_value";
|
||||
$where[] = "json_extract(" . iFace::COLUMN_META_DATA . ",'$.{$sField}') LIKE \"%\" || :jf_metadata_value || \"%\"";
|
||||
$params['jf_metadata_value'] = $sValue;
|
||||
}
|
||||
|
||||
@@ -218,7 +218,7 @@ final class ListCommand extends Command
|
||||
);
|
||||
}
|
||||
|
||||
$where[] = "json_extract(" . iFace::COLUMN_EXTRA . ",'$.{$sField}') = :jf_extra_value";
|
||||
$where[] = "json_extract(" . iFace::COLUMN_EXTRA . ",'$.{$sField}') LIKE \"%\" || :jf_extra_value || \"%\"";
|
||||
$params['jf_extra_value'] = $sValue;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user