MySQL Syntax error when locally importing dump from Amazon MySQL RDS?

后端 未结 2 955
春和景丽
春和景丽 2021-01-24 21:43

When I create a database dump from Amazon RDS and then I try to import it locally, the result is ERROR 1064 (42000) at line 54.

At line 54 there is the foll

2条回答
  •  余生分开走
    2021-01-24 22:03

    The problem is with datetime(6). MySql introduced storing of fractional seconds in v5.6.4. The syntax for indicating fractional seconds in datetime - this is the (6) - is not recognised by previous mysql versions.

    The data was exported from a mysql v5.6.4 or later, and was attempted to be imported into an earlier version. Since the error message starts with (6), I believe that this is the problem.

提交回复
热议问题