Add-CMSoftwareUpdateToGroup
Add-CMSoftwareUpdateToGroup
Adds a software update to a software update group in Configuration Manager.
Syntax
Parameter Set: AddSoftwareUpdateToGroupById_Id
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupId <String> -SoftwareUpdateId <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupById_Name
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupName <String> -SoftwareUpdateId <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupById_Object
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroup <IResultObject> -SoftwareUpdateId <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByName_Id
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupId <String> -SoftwareUpdateName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByName_Name
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupName <String> -SoftwareUpdateName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByName_Object
Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroup <IResultObject> -SoftwareUpdateName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByObject_Id
Add-CMSoftwareUpdateToGroup -SoftwareUpdate <IResultObject> -SoftwareUpdateGroupId <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByObject_Name
Add-CMSoftwareUpdateToGroup -SoftwareUpdate <IResultObject> -SoftwareUpdateGroupName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]
Parameter Set: AddSoftwareUpdateToGroupByObject_Object
Add-CMSoftwareUpdateToGroup -SoftwareUpdate <IResultObject> -SoftwareUpdateGroup <IResultObject> [-Confirm] [-WhatIf] [ <CommonParameters>]
Detailed Description
The Add-CMSoftwareUpdateToGroup cmdlet adds a software update to a software update group in Microsoft System Center 2012 Configuration Manager. You can specify a software update by name or by ID or use the Get-CMSoftwareUpdate cmdlet to obtain an update. Likewise, you can specify a software update group by name or by ID or use the Get-CMSoftwareUpdateGroup cmdlet to obtain one.
Parameters
-SoftwareUpdate<IResultObject>
Specifies a software update object. To obtain a software update object, use the Get-CMSoftwareUpdate cmdlet.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SoftwareUpdateGroup<IResultObject>
Specifies a software update group object. To obtain a software update group object, use the Get-CMSoftwareUpdateGroup cmdlet.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SoftwareUpdateGroupId<String>
Specifies an ID of a software group.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SoftwareUpdateGroupName<String>
Specifies a name of a software group.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SoftwareUpdateId<String>
Specifies an ID of a software update.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SoftwareUpdateName<String>
Specifies a name of a software update.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-Confirm
Prompts you for confirmation before running the cmdlet.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? |
false |
Position? |
named |
Default Value |
false |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
Outputs
The output type is the type of the objects that the cmdlet emits.
Examples
Example 1: Add an update to a software group
This command adds a software update with the ID SMS00078 to the update group named Accounting Group updates.
PS C:\> Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupName "Accounting Group updates" -SoftwareUpdateId "SMS00078"
Example 2: Add an update to a software group by using IDs
This command adds a software update that has the ID SMS00078 to the update group with the specified ID.
PS C:\> Add-CMSoftwareUpdateToGroup -SoftwareUpdateGroupId "SUP00045" -SoftwareUpdateId "SMS00078"