New-RestoreFolder cmdlet

New-RestoreFolder cmdlet

 

Applies To: SQL Server 2016

Restores an original folder to a new folder.

New-RestoreFolder [-OriginalFolder] <String> [-NewFolder] <String> [-AsTemplate] [-Server <String>] [-Credential <PSCredential>] [-Verbose] [-Debug] [-ErrorAction <ActionPreference>] [-WarningAction <ActionPreference>] [-ErrorVariable <String>] [-WarningVariable <String>] [-OutVariable <String>] [-OutBuffer <Int32>] [-WhatIf] [-Confirm]

New-RestoreFolder [-Server <String>] [-Credential <PSCredential>] [-Verbose] [-Debug] [-ErrorAction <ActionPreference>] [-WarningAction <ActionPreference>] [-ErrorVariable <String>] [-WarningVariable <String>] [-OutVariable <String>] [-OutBuffer <Int32>] [-WhatIf] [-Confirm]

Common parameters, such as –Verbose, -Debug, error and warning parameters, -Whatif, and –Confirm are documented in the Windows PowerShell reference. For more information, see about_CommonParameters.

The New-RestoreFolder cmdlet is used to create a new folder based on the name of the original folder.

-OriginalFolder <string>

Gets the original folder location.

Required?true
Position?0
Default value
Accept pipeline input?true
Accept wildcard characters?false

-NewFolder <string>

Sets the location of a new folder.

Required?true
Position?1
Default value
Accept pipeline input?true
Accept wildcard characters?false

-AsTemplate <SwitchParameter>

Specifies whether the object should be created in memory and returned.

Required?false
Position?named
Default value
Accept pipeline input?false
Accept wildcard characters?false

-Server <string>

Specifies the Analysis Services instance to which the cmdlet will connect and execute. If no server name is provided, a connection will be made to localhost. For default instances, specify just the server name. For named instances, use the format servername\instancename. For HTTP connections, use the format http[s]://server[:port]/virtualdirectory/msmdpump.dll.

Required?false
Position?named
Default valuelocalhost
Accept pipeline input?false
Accept wildcard characters?false

-Credential <PSCredential>

This parameter is used to pass in a username and password when using an HTTP connection to an Analysis Service instance, for an instance that you have configured for HTTP access. For more information, see Configure HTTP Access to Analysis Services on Internet Information Services (IIS) 8.0 and PowerShell scripting in Analysis Services for HTTP connections.

If this parameter is specified, the username and password will be used to connect to the specified Analysis Server instance. If no credentials are specified default windows account of the user who is running the tool will be used.

To use this parameter, first create a PSCredential object using Get-Credential to specify the username and password (for example, $Cred=Get-Credential “adventure-works\bobh”. You can then pipe this object to the –Credential parameter (-Credential:$Cred).

Required?false
Position?named
Default value
Accept pipeline input?True (ByValue)
Accept wildcard characters?false

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

Inputs
OutputsNone

PowerShell scripting in Analysis Services
Manage Tabular Models Using PowerShell

Community Additions

ADD
Show:
© 2016 Microsoft