mysql - Best way to export DB data in PHP, modify it, and import it -


i need export data in selected tables mysql database , import mysql database different structure. iow, need modify data between export , import (and not field names).

i've tried using json_encode , json_decode , works, if data not pure utf8, json_encode falls on , utf8_encode doesn't solve this.

i'm considering csv, serialize, , generating sql in php. of options give me reliable transfer?

you use pdo query , create array of objects can directly modified in code. use data import other database.

the better question why utf-8 isn't working you. make sure using recent version of php. make sure using mb_ prefixed functions maintain utf-8 (or other multibyte) encoding.

list of php multibyte string functions


Comments

Popular posts from this blog

javascript - How to synchronize the Three.js and HTML/SVG coordinate systems (especially w.r.t. the y-axis)? -

javascript - How do I find how many occurences are there of a highlighted string, and which occurence is it? -

java - Reading data from multiple zip files and combining them to one -