SQL query
Output
What I need to be as output
Need out put as below:
"l22s '" => "l22s ."
If there are any HTML encoded strings , I need to decode them in select.
SQL query
Output
What I need to be as output
Need out put as below:
"l22s '" => "l22s ."
If there are any HTML encoded strings , I need to decode them in select.
Try this, you need to extend WHEN POSITION(... IN locations.name) THEN REPLACE(locations.name, ..., ...)
statements as much as you need.
SELECT REPLACE(locations.name, ''', '.')
FROM `locations`
SELECT
CASE
WHEN POSITION("'" IN locations.name) THEN REPLACE(locations.name, ''', '.')
WHEN POSITION(<yourSecondItem> IN locations.name) THEN REPLACE(locations.name, <yourSecondItem>, <yourSecondReplaceItem>)
END AS `Name`
FROM `locations`
WHERE <yourWhereCriteria>