Requirements:
A remote table userinfo_remote, database encoding gbk, proofreading set is gbk_chinese_ci, fields (uid, username, password, email,... others) where username is the only index
It is necessary to take certain fields (uid, username, password) from the remote table, and then write them into the local table userinfo_local. The local table encoding is utf8, and the proofing set is utf8_general_ci, in which username is the only index.
Question:
In the remote database, it was found that there are users such as the following users
uid=12, username=coco,
uid=234, username=CǒCǒ,
in When writing to the local database, a duplicate username error is reported, such errors are reported, and there are others.
Solution: Without changing the proofing set (because userinfo_local will be used as a new user table later in the project) There is a user registration function, but I hope to still maintain the case-insensitive requirement), how to transfer the data of the remote table to the new table~~~~? I beg the master