[DBAL-830] Fix SQL Server default constraint name generation for quoted identifiers#672
Merged
Ocramius merged 2 commits intodoctrine:masterfrom Sep 10, 2014
Merged
[DBAL-830] Fix SQL Server default constraint name generation for quoted identifiers#672Ocramius merged 2 commits intodoctrine:masterfrom
Ocramius merged 2 commits intodoctrine:masterfrom
Conversation
Member
Author
|
/cc @DeepDiver1975 |
Member
|
👍 here |
Ocramius
added a commit
that referenced
this pull request
Sep 10, 2014
[DBAL-830] Fix SQL Server default constraint name generation for quoted identifiers
Contributor
|
@deeky666 I finally did find the time to test this - works now - many thanks! |
This was referenced Dec 6, 2015
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This is a replacement for #539.
It makes the generation of default constraint names consistent for quoted and unquoted identifiers by always unquoting them before generating the hash. This is the only possibility to ensure that the same hash is always generated for the same identifiers.
Unfortunately this introduces a minor BC break for existing applications that use either reserved keywords or explicitly quoted identifiers for columns with a declared default value and want to alter those columns in the future. It will generate
DROP CONSTRAINT/ADD CONSTRAINTstatements with different contraint names for the first time for a table alteration on existing v2.4 schemas.