can't insert russian text into mysql database

前端 未结 5 2371
青春惊慌失措
青春惊慌失措 2020-12-03 06:29

When I\'m trying to insert russian text into MySQL database it inserts it like: г???????????? ?? ????????
Рісѓрїр°ріс‹рї р° с‹рір°рї

So, I have two pages: regist

5条回答
  •  情深已故
    2020-12-03 06:50

    I store greek in tables created like ths:

    CREATE TABLE `test` (
      `test_id` SMALLINT UNSIGNED NOT NULL   AUTO_INCREMENT,
      `test_name` VARCHAR(30)  NOT NULL,
      PRIMARY KEY  (`test_id`)
     ) ENGINE=InnoDB   DEFAULT CHARSET=utf8 ROW_FORMAT=COMPACT;
    

    Or if table already created I guess you can change the charset it in the phpmyadmin interface. Maybe this helps.

提交回复
热议问题