Share via


Set-SCSPFConnectionString

Sets the connection string to the database used by the Service Provider Foundation service.

Syntax

Empty (Default)

Set-SCSPFConnectionString
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

FromConnectionStringConnectionStringParameterSetName

Set-SCSPFConnectionString
    -ConnectionString <String>
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

The Set-SCSPFConnectionString cmdlet sets the database connection string to the database used by the Service Provider Foundation service. The database used by the Service Provider Foundation and the Service Provider Foundation service do not have to be on the same server.

This cmdlet requires running Windows PowerShell as an administrator.

Examples

Example 1: Set the connection string

PS C:\>Set-SCSPFConnectionString -ConnectionString "Data Source=ContosoServerSFPDB_72,1433;Database=SCSPFDB;Integrated Security=True;MultipleActiveResultSets=True;"

This command sets the connection string to the database used by the Service Provider Foundation service on a server with the name ContosoServerSFPDB_72.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Parameter properties

Type:System.Management.Automation.SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ConnectionString

Specifies the connection string to the database used by the Service Provider Foundation service.

Parameter properties

Type:System.String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

FromConnectionStringConnectionStringParameterSetName
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Parameter properties

Type:System.Management.Automation.SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

None

Outputs

System.Object