Answer the question
In order to leave comments, you need to log in
NodeJS + Mysql how to set encoding?
Good afternoon. NodeJS and Mysql writes krakozyabry.
Settings
var connection = mysql.createConnection({
charset: "utf8_general_ci",
host: config.mysql.host,
user: config.mysql.user,
password: config.mysql.password,
database: config.mysql.database
});
mysql.query("INSERT INTO `user` (`firstname`) VALUES ('ТУТ ТЕКСТ НА РУССКОМ')");
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question