GnuBoard Backup Practice

GnuBoard Backup Practice

To convert the existing DB from euc-kr to utf8, I carefully took a backup (??),

When I opened it with editplus, it mentioned that there are characters that might be lost in the current encoding,

I ignored it for now and switched to UTF8 and imported… Damn, it didn’t work because of the broken characters ㅠㅠ

I started frantically searching~~~~ but I couldn’t find a solution..

(Even when I provide all options including -default-character-set while dumping, it doesn't work like this ㅠㅠ)

Reluctantly, I found the source below and modified it to my taste (UTF8 conversion, select desired tables)

Migration check complete!!!! - Migrating is always a hassle, so tiring ㅠㅠ

 

[PHP]
0)
{
$backText = ”
# MysqlDump
# Host: “.$mysql_host.”
# Processed time: “.date(‘Y년 n월 j일 H시 i분’).”
# Server version: “.mysql_get_server_info().”
# Database : `”.$mysql_db.”`
# ——————————————————–nnnnn”;

while($rows = mysql_fetch_row($tables[0]))
{
$chk = false;
for($i=0;$i
[/PHP]

Leave a Reply

이메일 주소는 공개되지 않습니다. (* 질문, 건의사항 등은 "질문게시판"을 이용해주세요)