We use SSDT in VS 2015 to manage our database project code. Recently, we've been implementing partitioning on some tables in databases that are managed with SSDT.
I need to include the partition function and partition scheme definition in my project if I want to declare a dependency on that scheme in my table definitions. I'd prefer to ignore changes to the scheme and function so we can manage that outside of the project.
The problem I am having is that SSDT's publish profile appears to not be honoring my partition scheme exclusion settings even though they appear to be set correctly.
When I go to Advanced options in the publish profile settings and click on the Ignore tab, I have "Ignore partition schemes" and "Ignore table options" checked in the top box as well as "Exclude partition schemes" and "Exclude partition functions" checked in the bottom box.
Unchecking the option for partition functions appears to be behaving properly. When checked, the function disappears from the generated deployment script. However, regardless of which options I check and uncheck in regards to the partition scheme the partition scheme still appears in the publish script.
This is a screenshot of my settings: screenshot
I recently upgraded from SSDT v14.0.61707.300 to v14.0.61712.050 but the behavior still exists (the latest release 17.4 on the MS site) https://learn.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt
Can anyone explain what I'm doing wrong or is this a confirmed bug?
Is the partition scheme forced to exist in the publish script under certain circumstances that my project may be affected by?
I'd rather not have to completely remove all partitioning definitions from the project in order to work around this single issue as it will obscure the definitions.
-
Does the object already exist in your SSDT project?Anthony Genovese– Anthony Genovese2017年12月22日 21:25:25 +00:00Commented Dec 22, 2017 at 21:25
-
@AnthonyGenovese yes it doesAlf47– Alf472017年12月27日 16:23:55 +00:00Commented Dec 27, 2017 at 16:23
-
maybe try deleting the object in the project. Saving the solution, then seeing what happens?Anthony Genovese– Anthony Genovese2017年12月27日 20:53:26 +00:00Commented Dec 27, 2017 at 20:53
-
Maybe this post contains relevant information? I'm attempting to do something similar.David Rogers– David Rogers2018年10月23日 21:00:31 +00:00Commented Oct 23, 2018 at 21:00
1 Answer 1
When performing a deploy where partition changes are occurring in a way that negatively impacts the performance, it is recommended to use the publish property "/p:IgnoreTablePartitionOption". With this option, table partition changes are not included in the deployment.
-
It sounds like chatgpt, which is not always right. Do you have a reference for thisRohit Gupta– Rohit Gupta2023年05月24日 09:27:42 +00:00Commented May 24, 2023 at 9:27