When using SQL, are there any benefits of using =
in a WHERE
clause instead of LIKE
?
Without any special operators, LIKE
The LIKE keyword undoubtedly comes with a "performance price-tag" attached. That said, if you have an input field that could potentially include wild card characters to be used in your query, I would recommend using LIKE only if the input contains one of the wild cards. Otherwise, use the standard equal to comparison.
Best regards...