Set-SCSQLProfile

Modifies the properties of a SQL Server profile.

Syntax

Set-SCSQLProfile
   [-VMMServer <ServerConnection>]
   [-SQLProfile] <SQLProfile>
   [-Name <String>]
   [-Description <String>]
   [-Owner <String>]
   [-UserRole <UserRole>]
   [-Tag <String>]
   [-RunAsynchronously]
   [-PROTipID <Guid>]
   [-JobVariable <String>]
   [<CommonParameters>]

Description

The Set-SCSQLProfile cmdlet modifies the properties of a Microsoft SQL Server profile.

Examples

Example 1: Change the name and description of a SQL Server profile

PS C:\> $SQLProfile = Get-SCSQLProfile -Name "SQLProfile01"
PS C:\> Set-SCSQLProfile -SQLProfile $SQLProfile -Name "SQLProfile02" -Description "SQL Profile 02"

The first command gets the SQL Server profile named SQLProfile01, and then stores that object in the $SQLProfile variable.

The second command renames the SQL Server profile stored in $SQLProfile and changes its description.

Required Parameters

-SQLProfile

Specifies the SQL Server profile that this cmdlet modifies.

Type:SQLProfile
Position:0
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Optional Parameters

-Description

Specifies a description that this cmdlet modifies for the SQL Server profile.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobVariable

Specifies a variable in which job progress is tracked and stored.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the new name of the SQL Server profile.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Owner

Specifies the owner of a SQL Server profile. Specify a valid domain user account in the following formats:

  • Contoso\DavidCh
  • DavidCh@Contoso
Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PROTipID

Specifies the ID of the Performance and Resource Optimization (PRO) tip that triggered this action. This allows for auditing of PRO tips.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Tag

Specifies a word or phrase that this cmdlet associates to an object. You can search for a subset of tags, or you can search for the full set of tags.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-UserRole

Specifies the user role for the SQL Server profile.

Type:UserRole
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies the VMM server on which this cmdlet operates.

Type:ServerConnection
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False

Outputs

SQLProfile

This cmdlet returns a SQLProfile object.