I am trying to find a MySQL database using PHP, the search works fine, but I am looking for a little help using wildcards:
The data in the (Model) field I'm looking for is: "A4" (215 results)
My search string:
SELECT * FROM `temp_comp`.`mvl` WHERE `Model` LIKE '%A4 Avant%'
Is there a way I can find βA4 Avantβ, but that will return any fields containing βA4β or βAvantβ
The search query was taken from the csv file, so I wanted to try and do it without first breaking two words and not distorting "A4" and / or "Avant", I tried the following, but did not get the results
SELECT * FROM `temp_comp`.`mvl` WHERE `Model` LIKE '%A4%Avant%'
As you may have guessed, this is not my normal field, so any help would be greatly appreciated.
source share