-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v9: SQL error when trying to create a new property on a tab that is inherited from a Composition (SQL CE and LocalDB) #11221
Comments
Just to follow up quickly, this seems to be a showstopper for SQL CE, as it happens without any renaming shenanigans - simply by trying to add a local document type property to an composition-inherited tab. I have repro'd this on a fresh install, without doing steps 4,5 or 6 above i.e. I have updated my original post accordingly.
The SQL error regarding a duplicate index in IX_cmsPropertyTypeGroupUniqueID is triggered. |
Thanks @BarryFogarty - likely a v8 problem too with tabs. Will do some testing to confirm. |
I've gotten this exception as well this morning while testing things for issue #11202, so I can confirm it's indeed a bug. Looks like the back-office doesn't generate a new GUID for the new local group/tab and tries to save it using the key inherited from the composition, causing the duplicate key exception. This issue wasn't surfaced in 8.17 RC1, as the keys weren't posted back to the server and therefore re-created on every save and thus unique (which is a bug that's fixed in PR #11121). |
I noticed this as well when migrating a v8 Cloud project to v9 where I had a base composition to hold Background Color and Text Color properties: |
I've just encountered this issue using normal SQL Server when trying to add a property to a composition in v9
|
@ronaldbarendse Is there a work around for this? The reason being I can't continue with my build until it works 🙈 |
@AaronSadlerUK You can temporary patch the changed files from PR #11231 (please report back, also if it worked correctly) or:
|
Cherry picked for 8.17.0 in 213d8c0 - this will also be merged up to v9 for a 9.0.1 release. |
Cherry picked for 9.0.1 in 5a3efa7 |
@nul800sebastiaan Any ideas when 9.0.1 is out, I have been blocked since 9.0.0 release due to this issue 😕 I also couldn't figure out how to regenerate the minified files to include @ronaldbarendse fix |
I am still experiencing this in 9.0.1, although I can confirm that @ronaldbarendse workaround does work for me. |
Which exact Umbraco version are you using? For example: 8.13.1 - don't just write v8
9.0.0
Bug summary
A SQL error is generated when trying to create a new property on a tab that is inherited from a Composition (using SQL CE). The error is: A duplicate value cannot be inserted into a unique index. [ Table name = cmsPropertyTypeGroup,Constraint name = IX_cmsPropertyTypeGroupUniqueID ]
I believe this is caused by a rename of the tab in the Composition, and/or on the Document Type prior to the Save attempt.
Specifics
Received an error from the server
Steps to reproduce EDITED
I believe this only happened when I renamed a tab in the Composition, and then attempted to move the property in the target document type into this inherited tab.So, steps:4. Rename the tab in the Composition5. Rename the tab in the Document Type (note they are not merged)6. Move the Document Type property to the renamed inherited tabIt is not possible to save any properties in tabs that are inherited from compositions.
Expected result / actual result
Umbraco should be able to save the Document Type after adding properties on tabs inherited that are inherited from compositions. Instead, a server error dialog appears with the above 'duplicate index in IX_cmsPropertyTypeGroupUniqueID' exception message.
The text was updated successfully, but these errors were encountered: