Hi All,
I am calling Google Translate URL from a Select query as below. This is to convert from English to Vietnamese.
SELECT REGEXP_SUBSTR(tr,'<span id=result_box class="short_text"><span[^>]*>(.*)</span></span>',1,1,'i',1) translated_value
FROM (SELECT httpuritype('http://translate.google.com/?hl=en&layout=1&eotf=1&sl=en&tl='||'vi'||'&text='|| UTL_URL.escape('My text to be converted')|| '#').getclob() tr
FROM DUAL);
The expected result is: (Checked on google.com/translate from web and in the page source the charset was UTF-8)
Văn bản của tôi được chuyển đổi What I got it is: (Checked the clob returned by httpuritype and the charset was ISO-8859-1)
Văn bản của tôi được chuyển đổ
Please, any help on getting the expected result
Regards,
Narender