Incorrect datetime value
Community wiki answer:


  Running SELECT NOW() gives me 2017-09-27 11:47:38, it's a DATETIME(19) field.


Not (19), the number is the number of decimal places in the seconds.


  What kind of transformation is needed so that I can insert the right time in my database?


MySQL has no concept of time zone representation.

That is there is no way to use (read or write) -07:00.