Comments (3)
I've had a quick look into this, and it appears the wording on the website is slightly different to what you are trying to achieve.
- If the input date string has no time portion (ie
2023-12-28
) the value would be stored as2023-12-28 00:00:00
- If the input string has a time potion and no timezone information (ie
2023-12-28 02:00:00
), the value is converted the local time as then stored in the database as UTC
To have the input string value treated as UTC, you need to have a datetime string with the UTC time zone, for example:
2023-12-28 02:00:00+00:00
2023-12-28 02:00:00Z
from sequelize.
Sorry, does that mean the wording on the website is incorrect or that there's more subtlety to the date datatype?
In Sequelize 6, an input such as 2022-11-06 was parsed as local time... Starting with Sequelize 7, that input is parsed as UTC ...
Is this correct?
2023-12-28
treated as UTC
2023-12-28 02:00:00
not treated as UTC
from sequelize.
Yes, that sounds correct
from sequelize.
Related Issues (20)
- Backport stream dialectOption to v6 HOT 1
- Mysql not insert 0 to column HOT 1
- eager loading error when calling getAll() function HOT 1
- sequelize reference error relation not defined HOT 2
- There is a problem with the handling of the bigint HOT 1
- settings raw as true in sqlite returns JSON as String HOT 2
- DeprecationWarning: The URL `sqlite://:memory:` is invalid HOT 3
- Increment or Decrement value using Sequelize upsert() does not work in postgre HOT 1
- addProfile is not function on many to many relationship
- Incorrect types for default in findOrCreate and findOrBuild HOT 2
- Support Automatic Transaction Nesting When Using `cls-hooked` HOT 2
- UPDATE database ignoring case of data objects HOT 1
- onUpdate option in association not working
- `sequelize.query` doesn't accept `Literal` HOT 2
- UpdateOptions is missing plain property HOT 1
- Publish latest alpha to NPM alpha tag, including Postgres connectionTimeoutMillis HOT 3
- Special method/mixin "add" for BelongsToMany association overrides record instead of creating a new one
- SequelizeConnectionAcquireTimeoutError: Operation timeout HOT 3
- Regression between 6.35.1 and 6.35.2 - query stopped working. HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sequelize.