Set internal default property value to undefined instead of null & add PostgreSQL uuid support#855
Merged
Set internal default property value to undefined instead of null & add PostgreSQL uuid support#855
Conversation
cdc6eee to
43cb7b4
Compare
This will prevent null values being explicitly sent to the database when no value was assigned and instead result in the database setting the column to null, or generating a default value. Properties with an internal value of undefined will still return null when accessed. Setting a previously filled property to undefined will still set it to null in the DB. No ORM tests were broken by this change, and as such, the impact of this should be limited ot a very small number of corner cases. Add PostgreSQL uuid column support. Allow specifying defaultExpression (eg. uuid_generate_v4() for PostgreSQL or uuid() for MySQL) to be executed by the database engine for generating default values.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Set internal default property value to undefined instead of null.
Add PostgreSQL uuid column support.
Allow specifying defaultExpression (eg. uuid_generate_v4() for PostgreSQL or uuid() for MySQL) to be executed by the database engine for generating default values.