Back up a table with a GEOMETRY column using mysqldump?

前端 未结 4 444
误落风尘
误落风尘 2021-01-12 21:22

I recently created a MySQL table with a column of type GEOMETRY.

When I back up the table with mysqldump, it outputs my geometry column as a quoted string, containin

4条回答
  •  隐瞒了意图╮
    2021-01-12 21:49

    I once faced this issue but manage to passthrough by using gzip. Please check my sample commands: Export:

    mysqldump -u root -p db_name | gzip > dump.sql.gz
    

    Import:

    pv dump.sql.gz | gunzip | mysql -u root -p other_db
    

提交回复
热议问题