-
Notifications
You must be signed in to change notification settings - Fork 228
Open
Labels
enhancementThe issue is an enhancement request.The issue is an enhancement request.in progressThe issue is being actively worked on by someone.The issue is being actively worked on by someone.
Description
Description
Add a new command Set-SqlDscDatabaseDefaultFileGroup to set the default filegroup and default FILESTREAM filegroup for a SQL Server database using the SMO SetDefaultFileGroup() method.
Context
This command is needed to handle database filegroup settings that require SMO method calls rather than simple property assignments. The SetDefaultFileGroup() and SetDefaultFileStreamFileGroup() method should be used to configure:
- DefaultFileGroup
- DefaultFileStreamFileGroup
Proposed Solution
Create a new public command Set-SqlDscDatabaseDefaultFileGroup that:
- Accepts either ServerObject + Name or DatabaseObject parameter sets (following the pattern established in Set-SqlDscDatabaseOwner)
- Uses the SMO
SetDefaultFileGroup()method to apply changes - Supports ShouldProcess, Force, and PassThru parameters
- Includes appropriate parameter validation and error handling
Related
- Original issue:
Set-SqlDscDatabase: Add parameters to command #2177 - Implementation PR:
Set-SqlDscDatabaseProperty: Refactor command #2327 - Comment:
Set-SqlDscDatabaseProperty: Refactor command #2327
Requested by @johlju
Metadata
Metadata
Assignees
Labels
enhancementThe issue is an enhancement request.The issue is an enhancement request.in progressThe issue is being actively worked on by someone.The issue is being actively worked on by someone.