An example of creating one of the table columns:

`f_stamp` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' 

Previously, on Ubuntu 14.04.4 [ mysql 5.6 ], the value of this field was displayed normally, at the moment, when Ubuntu 16.06 and mysql 5.7 are installed, it is displayed as null.


What did: removed from the global variable flags: NO_ZERO_DATE, NP_ZERO_IN_DATE and STRICT_TRANS_TABLES.


As a result, looking at this field on the server via mysql-client β€” the field is displayed as I would like ('0000-00-00 00:00:00'), however, when connecting to DataGrip 'from a remote machine - I see null again, though earlier all the same DataGrip showed the necessary value.

UPD: [for those who closed the question] In the Database Administrators this question was answered. Well, this is me, note.

UPD2: [for those who closed the question, of course] - https://youtrack.jetbrains.com/issue/DBE-3377

  • Try to create a database dump and re-roll it in a new way. Most likely some kind of migration error. On a clean installation, a new table, the situation is not reproduced. - cheops
  • one
    Thanks for the advice ! But after changing the above flags, everything worked, it only worries me that DataGrip displays such fields incorrectly. - isnullxbh am
  • one
    It is worth adding that in addition to the fact that I removed a few flags, I added one more: ALLOW_INVALID_DATES . And another little advice for those who have never indulged with flags - initialize the sql_mode variable in the mysql.cnf file, and don't forget to check that the line [mysqld] is in this file. - isnullxbh
  • @cheops, if you are interested in the reason - see, updated the post. - isnullxbh
  • Thank. Voted for reopening, if enough votes are gathered, please place the decision in response. I think it will be interesting to many. - cheops

0