Importing Unicode from MySQL

Devin Asay devin_asay at
Wed Jul 26 11:47:18 EDT 2017


Thanks for that tip. It’s one I never have heard about. I’ll try this next time I need to read UTF8 from my db.


On Jul 26, 2017, at 1:03 AM, AndyP via use-livecode <use-livecode at<mailto:use-livecode at>> wrote:

I had the same problems a while ago, but got it sorted with the following.

*Before* you do any interactions with the db, add this line.

*revExecuteSQL MyConnectionID, "SET NAMES 'utf8'"*

"SET NAMES 'utf8'" is needed whenever you want to send/retrieve data
to/from the server having characters that cannot be represented in pure
ASCII, like 'ñ' or 'ö'.

Then retrieve the data

*put textDecode("SELECT * FROM MyTable","UTF-8")  into fld "MyField"*

Andy Piddock

My software never has bugs. It just develops random features.

TinyIDE a Free alternative minimalist IDE Plugin for LiveCode

Script editor Themer for LC

PointandSee is a FREE simple but full featured under cursor colour picker / finder.  - made with LiveCode
View this message in context:
Sent from the Revolution - User mailing list archive at<>.

use-livecode mailing list
use-livecode at<mailto:use-livecode at>
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:

Devin Asay
Office of Digital Humanities
Brigham Young University

More information about the Use-livecode mailing list