Convert fbk (firebird) file to MySql

2019-06-13 01:22发布

I have firebird database file and I want to convert it into Mysql, but I don't know how. Can you help me how to convert it? Or can you give me the reference what software I have to use to convert it?

Thank you

1条回答
Luminary・发光体
2楼-- · 2019-06-13 02:07

You have to use FBExport tool to generate a dump with inserts

FBExport.exe -D "c:\DB\WL.FDB" -U user –P password -Si -V TEST -F test.out
Where: 
Si – means “export to SQL inserts” format
V – table name to export
F – output filename

Be careful with dates in mysql. Export in the correct format. To export db in custom date format use:

$> FBExport.exe -D "c:\DB\WL.FDB" -U user –P password -Si -V TEST -F     test.out -J "Y-M-D" -K "H:M:S"
Where: 
J  - date format
K – time format

To import date to mySQL use SOURCE command:

$> mysql --user=root --password=password
$> use  database_name
$> SOURCE  c:\export\table_name.out

Ref: http://kosiara87.blogspot.nl/2011/03/export-data-from-firebird-into-pure-sql.html

查看更多
登录 后发表回答