mysql - Why doesn't "Like" match a query when equal does? -


in following query, match found:

select * images originalpath =   "d:\\pic16\\160623 bugs\\rw2-jpg\\p1280627.jpg"; 

however, match not found using "like":

select * images originalpath   "d:\\pic16\\160623 bugs\\rw2-jpg\\p1280627.jpg"; 

i same result using "\" before " ", ":", "-", , ".":

select * images originalpath   "d\:\\pic16\\160623\ bugs\\rw2\-jpg\\p1280627\.jpg"; 

how can make match using like? (mysql 5.6, innodb)

i think reason because need slash every slash when writing expression try select * images originalpath "d:\\\\pic16\\\\160623 bugs\\\\rw2-jpg\\\\p1280627.jpg"; while writing expression because characters can have different meaning need escaped in order show literal.


Comments