Foreign key constraints while dumping data

后端 未结 1 1709
眼角桃花
眼角桃花 2021-01-29 07:24
mysqldump --compact --no-create-info -h192.168.150.180 -uroot -p live pnlbus_stops | sed s/pnlbus_stops/bus_stops/g | mysql test

I am getting an error:

相关标签:
1条回答
  • 2021-01-29 07:52

    put

    set FOREIGN_KEY_CHECKS = 0;
    

    at the top of your dump file

    and put

    SET FOREIGN_KEY_CHECKS = 1;
    

    at the bottom of your dump file

    0 讨论(0)
提交回复
热议问题