We use Sql Server database projects to create deployment scripts with DacPac using SqlPackage.exe. We have different settings for SQL Server filegroups in different environments. During deployment, we exclude FileGroups, since we want objects to be created in the filegroup by default. In the database project settings, the standard filegroup does not change from PRIMARY.
This creates a problem when trying to deploy an environment in which the standard filegroup is not PRIMARY because the following code is included ...
ALTER DATABASE [$(DatabaseName)] MODIFY FILEGROUP [PRIMARY] DEFAULT;
Is there a way to prevent this from being created in SQL deployment?
source share