MySQL Workbench Import NULL from CSV

后端 未结 4 1454
不知归路
不知归路 2021-01-12 02:59

I can\'t for the life of me make MySQL Workbench import NULL for blank cells in a CSV.

I\'ve tried:

  • blank
  • NULL
  • \\N
  • Each wi
4条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-12 03:35

    If you were trying to import a CSV into the model for creating insert scripts (where you won't get the same options described in the other answers), try the following:

    \func NULL
    

    You can also use this syntax to call functions like the following to insert the current date time when you forward engineer the model to the database:

    \func CURRENT_TIMESTAMP
    

提交回复
热议问题