Understanding the REPLACE Command in MySQL

At times, it is necessary to replace full or partial value in a column. The following command will be handy in achieving the this result.

UPDATE TABLE_NAME SET COLUMN_NAME = REPLACE(COLUMN_NAME,'TEXT_TO_REPLACE','TEXT_TO_BE_REPLACED') WHERE CONDITION;
Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

Recent Articles: