Export (0) Print
Expand All
Expand Minimize

Remove-ASPersistenceSqlDatabase

Remove-ASPersistenceSqlDatabase

Remove all persistence artifacts from the specified SQL Server persistence database.

Syntax

Parameter Set: DatabaseName
Remove-ASPersistenceSqlDatabase -Database <String> [-Force] [-Server <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]


Detailed Description

This cmdlet deletes all persistence artifacts from the specified persistence database. All instances stored in that database are deleted. The database itself is not deleted because it might contain other artifacts.

Parameters

-ConnectionString<String>

The connection string that SQL Server persistence provider uses to connect to the persistence database. Example: “Data Source=(local);Initial Catalog=PersistenceDB;Integrated Security=True".


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

-Database<String>

Name of the persistence database. This parameter is a required parameter if –ConnectionString is not specified; otherwise, it is an optional parameter.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

-Force

If specified, an action that is attempted is performed even if restrictions are encountered (as long as security is not compromised). This is an optional parameter.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

-Server<String>

Specifies the database server on which the database needs to be created. The default value is “localhost”. You must not specify this parameter if the –ConnectionString is specified. This is an optional parameter.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

-Confirm

Prompts you for confirmation before executing the command.


Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Describes what would happen if you executed the command without actually executing the command.


Required?

false

Position?

named

Default Value

none

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

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • None.


Outputs

The output type is the type of the objects that the cmdlet emits.

  • None.


Examples

Example 1

Removes a persistence database.


Remove-ASPersistenceSqlDatabase –Database “PersistenceDB1” –Server “contosoDBserver”This operation will remove all persistence data from the database – do you wish to continue (Y/N)? YPersistence Store removed.

Example 2

Remove a persistence database without user confirmation.


Remove-ASPersistenceSqlDatabase –Database “PersistenceDB1” –Server “contosoDBserver” -force

Example 3

Remove a persistence database for a named connection string without user confirmation.


Remove-ASPersistenceDatabase –ConnectionString “Data Source=contosoDBserver; Initial Catalog= PersistenceDB1; User ID=me; Password=pass@word1” -force
Show:
© 2014 Microsoft