You can create function like below
DELIMITER $$
DROP FUNCTION IF EXISTS `HTML_UnEncode`$$
CREATE FUNCTION `HTML_UnEncode`(X VARCHAR(255)) RETURNS VARCHAR(255) CHARSET latin1 DETERMINISTIC
BEGIN
DECLARE TextString VARCHAR(255) ;
SET TextString = X ;
#quotation mark
IF INSTR( X , '"' )
THEN SET TextString = REPLACE(TextString, '"','"') ;
END IF ;
#apostrophe
IF INSTR( X , ''' )
THEN SET TextString = REPLACE(TextString, ''','"') ;
END IF ;
#ampersand
IF INSTR( X , '&' )
THEN SET TextString = REPLACE(TextString, '&','&') ;
END IF ;
#less-than
IF INSTR( X , '<' )
THEN SET TextString = REPLACE(TextString, '<','<') ;
END IF ;
#greater-than
IF INSTR( X , '>' )
THEN SET TextString = REPLACE(TextString, '>','>') ;
END IF ;
#non-breaking space
IF INSTR( X , ' ' )
THEN SET TextString = REPLACE(TextString, ' ',' ') ;
END IF ;
#inverted exclamation mark
IF INSTR( X , '¡' )
THEN SET TextString = REPLACE(TextString, '¡','?') ;
END IF ;
#cent
IF INSTR( X , '¢' )
THEN SET TextString = REPLACE(TextString, '¢','¢') ;
END IF ;
#pound
IF INSTR( X , '£' )
THEN SET TextString = REPLACE(TextString, '£','£') ;
END IF ;
#currency
IF INSTR( X , '¤' )
THEN SET TextString = REPLACE(TextString, '¤','¤') ;
END IF ;
#yen
IF INSTR( X , '¥' )
THEN SET TextString = REPLACE(TextString, '¥','¥') ;
END IF ;
#broken vertical bar
IF INSTR( X , '¦' )
THEN SET TextString = REPLACE(TextString, '¦','|') ;
END IF ;
#section
IF INSTR( X , '§' )
THEN SET TextString = REPLACE(TextString, '§','§') ;
END IF ;
#spacing diaeresis
IF INSTR( X , '¨' )
THEN SET TextString = REPLACE(TextString, '¨','¨') ;
END IF ;
#copyright
IF INSTR( X , '©' )
THEN SET TextString = REPLACE(TextString, '©','?') ;
END IF ;
#feminine ordinal indicator
IF INSTR( X , 'ª' )
THEN SET TextString = REPLACE(TextString, 'ª','a') ;
END IF ;
#angle quotation mark (left)
IF INSTR( X , '«' )
THEN SET TextString = REPLACE(TextString, '«','?') ;
END IF ;
#negation
IF INSTR( X , '¬' )
THEN SET TextString = REPLACE(TextString, '¬','?') ;
END IF ;
#soft hyphen
IF INSTR( X , '­' )
THEN SET TextString = REPLACE(TextString, '­','-') ;
END IF ;
#registered trademark
IF INSTR( X , '®' )
THEN SET TextString = REPLACE(TextString, '®','?') ;
END IF ;
#spacing macron
IF INSTR( X , '¯' )
THEN SET TextString = REPLACE(TextString, '¯','ˉ') ;
END IF ;
#degree
IF INSTR( X , '°' )
THEN SET TextString = REPLACE(TextString, '°','°') ;
END IF ;
#plus-or-minus
IF INSTR( X , '±' )
THEN SET TextString = REPLACE(TextString, '±','±') ;
END IF ;
#superscript 2
IF INSTR( X , '²' )
THEN SET TextString = REPLACE(TextString, '²','2') ;
END IF ;
#superscript 3
IF INSTR( X , '³' )
THEN SET TextString = REPLACE(TextString, '³','3') ;
END IF ;
#spacing acute
IF INSTR( X , '´' )
THEN SET TextString = REPLACE(TextString, '´','′') ;
END IF ;
#micro
IF INSTR( X , 'µ' )
THEN SET TextString = REPLACE(TextString, 'µ','μ') ;
END IF ;
#paragraph
IF INSTR( X , '¶' )
THEN SET TextString = REPLACE(TextString, '¶','?') ;
END IF ;
#middle dot
IF INSTR( X , '·' )
THEN SET TextString = REPLACE(TextString, '·','·') ;
END IF ;
#spacing cedilla
IF INSTR( X , '¸' )
THEN SET TextString = REPLACE(TextString, '¸','?') ;
END IF ;
#superscript 1
IF INSTR( X , '¹' )
THEN SET TextString = REPLACE(TextString, '¹','1') ;
END IF ;
#masculine ordinal indicator
IF INSTR( X , 'º' )
THEN SET TextString = REPLACE(TextString, 'º','o') ;
END IF ;
#angle quotation mark (right)
IF INSTR( X , '»' )
THEN SET TextString = REPLACE(TextString, '»','?') ;
END IF ;
#fraction 1/4
IF INSTR( X , '¼' )
THEN SET TextString = REPLACE(TextString, '¼','?') ;
END IF ;
#fraction 1/2
IF INSTR( X , '½' )
THEN SET TextString = REPLACE(TextString, '½','?') ;
END IF ;
#fraction 3/4
IF INSTR( X , '¾' )
THEN SET TextString = REPLACE(TextString, '¾','?') ;
END IF ;
#inverted question mark
IF INSTR( X , '¿' )
THEN SET TextString = REPLACE(TextString, '¿','?') ;
END IF ;
#multiplication
IF INSTR( X , '×' )
THEN SET TextString = REPLACE(TextString, '×','×') ;
END IF ;
#division
IF INSTR( X , '÷' )
THEN SET TextString = REPLACE(TextString, '÷','÷') ;
END IF ;
#capital a, grave accent
IF INSTR( X , 'À' )
THEN SET TextString = REPLACE(TextString, 'À','à') ;
END IF ;
#capital a, acute accent
IF INSTR( X , 'Á' )
THEN SET TextString = REPLACE(TextString, 'Á','á') ;
END IF ;
#capital a, circumflex accent
IF INSTR( X , 'Â' )
THEN SET TextString = REPLACE(TextString, 'Â','?') ;
END IF ;
#capital a, tilde
IF INSTR( X , 'Ã' )
THEN SET TextString = REPLACE(TextString, 'Ã','?') ;
END IF ;
#capital a, umlaut mark
IF INSTR( X , 'Ä' )
THEN SET TextString = REPLACE(TextString, 'Ä','?') ;
END IF ;
#capital a, ring
IF INSTR( X , 'Å' )
THEN SET TextString = REPLACE(TextString, 'Å','?') ;
END IF ;
#capital ae
IF INSTR( X , 'Æ' )
THEN SET TextString = REPLACE(TextString, 'Æ','?') ;
END IF ;
#capital c, cedilla
IF INSTR( X , 'Ç' )
THEN SET TextString = REPLACE(TextString, 'Ç','?') ;
END IF ;
#capital e, grave accent
IF INSTR( X , 'È' )
THEN SET TextString = REPLACE(TextString, 'È','è') ;
END IF ;
#capital e, acute accent
IF INSTR( X , 'É' )
THEN SET TextString = REPLACE(TextString, 'É','é') ;
END IF ;
#capital e, circumflex accent
IF INSTR( X , 'Ê' )
THEN SET TextString = REPLACE(TextString, 'Ê','ê') ;
END IF ;
#capital e, umlaut mark
IF INSTR( X , 'Ë' )
THEN SET TextString = REPLACE(TextString, 'Ë','?') ;
END IF ;
#capital i, grave accent
IF INSTR( X , 'Ì' )
THEN SET TextString = REPLACE(TextString, 'Ì','ì') ;
END IF ;
#capital i, acute accent
IF INSTR( X , 'Í' )
THEN SET TextString = REPLACE(TextString, 'Í','í') ;
END IF ;
#capital i, circumflex accent
IF INSTR( X , 'Î' )
THEN SET TextString = REPLACE(TextString, 'Î','?') ;
END IF ;
#capital i, umlaut mark
IF INSTR( X , 'Ï' )
THEN SET TextString = REPLACE(TextString, 'Ï','?') ;
END IF ;
#capital eth, Icelandic
IF INSTR( X , 'Ð' )
THEN SET TextString = REPLACE(TextString, 'Ð','D') ;
END IF ;
#capital n, tilde
IF INSTR( X , 'Ñ' )
THEN SET TextString = REPLACE(TextString, 'Ñ','?') ;
END IF ;
#capital o, grave accent
IF INSTR( X , 'Ò' )
THEN SET TextString = REPLACE(TextString, 'Ò','ò') ;
END IF ;
#capital o, acute accent
IF INSTR( X , 'Ó' )
THEN SET TextString = REPLACE(TextString, 'Ó','ó') ;
END IF ;
#capital o, circumflex accent
IF INSTR( X , 'Ô' )
THEN SET TextString = REPLACE(TextString, 'Ô','?') ;
END IF ;
#capital o, tilde
IF INSTR( X , 'Õ' )
THEN SET TextString = REPLACE(TextString, 'Õ','?') ;
END IF ;
#capital o, umlaut mark
IF INSTR( X , 'Ö' )
THEN SET TextString = REPLACE(TextString, 'Ö','?') ;
END IF ;
#capital o, slash
IF INSTR( X , 'Ø' )
THEN SET TextString = REPLACE(TextString, 'Ø','?') ;
END IF ;
#capital u, grave accent
IF INSTR( X , 'Ù' )
THEN SET TextString = REPLACE(TextString, 'Ù','ù') ;
END IF ;
#capital u, acute accent
IF INSTR( X , 'Ú' )
THEN SET TextString = REPLACE(TextString, 'Ú','ú') ;
END IF ;
#capital u, circumflex accent
IF INSTR( X , 'Û' )
THEN SET TextString = REPLACE(TextString, 'Û','?') ;
END IF ;
#capital u, umlaut mark
IF INSTR( X , 'Ü' )
THEN SET TextString = REPLACE(TextString, 'Ü','ü') ;
END IF ;
#capital y, acute accent
IF INSTR( X , 'Ý' )
THEN SET TextString = REPLACE(TextString, 'Ý','Y') ;
END IF ;
#capital THORN, Icelandic
IF INSTR( X , 'Þ' )
THEN SET TextString = REPLACE(TextString, 'Þ','T') ;
END IF ;
#small sharp s, German
IF INSTR( X , 'ß' )
THEN SET TextString = REPLACE(TextString, 'ß','?') ;
END IF ;
#small a, grave accent
IF INSTR( X , 'à' )
THEN SET TextString = REPLACE(TextString, 'à','à') ;
END IF ;
#small a, acute accent
IF INSTR( X , 'á' )
THEN SET TextString = REPLACE(TextString, 'á','á') ;
END IF ;
#small a, circumflex accent
IF INSTR( X , 'â' )
THEN SET TextString = REPLACE(TextString, 'â','a') ;
END IF ;
#small a, tilde
IF INSTR( X , 'ã' )
THEN SET TextString = REPLACE(TextString, 'ã','?') ;
END IF ;
#small a, umlaut mark
IF INSTR( X , 'ä' )
THEN SET TextString = REPLACE(TextString, 'ä','?') ;
END IF ;
#small a, ring
IF INSTR( X , 'å' )
THEN SET TextString = REPLACE(TextString, 'å','?') ;
END IF ;
#small ae
IF INSTR( X , 'æ' )
THEN SET TextString = REPLACE(TextString, 'æ','?') ;
END IF ;
#small c, cedilla
IF INSTR( X , 'ç' )
THEN SET TextString = REPLACE(TextString, 'ç','?') ;
END IF ;
#small e, grave accent
IF INSTR( X , 'è' )
THEN SET TextString = REPLACE(TextString, 'è','è') ;
END IF ;
#small e, acute accent
IF INSTR( X , 'é' )
TH