I need to remove trailing dot from my domain name. I have example below. What is the correct way to use it in the query?
$tank5 = "SELECT url FROM `db`.`tank` WHERE url LIKE rtrim('%$string%', '.')"; // this don't work I just test it.
I know I can just do this $string = rtrim($string, '.'); before the query but I was hoping I could run it on 1 line.
Is it actually possible? Thanks in advance.
Concatenate your string, instead: