1
I have a API with node.js and express.js. In the database the fields of the type datetime are saved correctly, but in response to a request GET date fields come with 3 hours more due to time zone.
I’m making this requisition and consuming the json in a web application and in an app android nativo.
I would like to know how I could resolve it. Is there any possibility to remove the timezone in the API, or should I set something up in the database or server? I’m using MySQL.
Example:
**DB:** 2017-10-02 10:58:34
**JSON:** "2017-10-02T13:58:34.000Z"
Can you put here the example of this string that comes from GET? has no time zone in the string?
– Sergio
I updated with the example.
– Fernando Zabin
Okay, two more questions: do you have control over the creation of the GET date? what is the BD date Timezone?
– Sergio
I do have.
@@system_time_zone: BRT,@@global.time_zone: SYSTEM,@@session.time_zone: SYSTEM.– Fernando Zabin