New-SPAccessServicesDatabaseServer

Adds a server to host Access Services databases.

Syntax

New-SPAccessServicesDatabaseServer
   [-ServiceContext] <SPServiceContextPipeBind>
   [-AssignmentCollection <SPAssignmentCollection>]
   [-AvailableForCreate <Boolean>]
   [-Confirm]
   [-DatabaseServerCredentials <PSCredential>]
   [-DatabaseServerGroupName <String>]
   -DatabaseServerName <String>
   [-Encrypt <Boolean>]
   [-Exclusive <Boolean>]
   [-SecondaryDatabaseServerName <String>]
   [-ServerReferenceId <Guid>]
   [-TrustServerCertificate <Boolean>]
   [-UserDomain <String>]
   [-ValidateServer <Boolean>]
   [-WhatIf]
   [-LoginType <LoginType>]
   [-State <DatabaseServerStates>]
   [-StateOwner <ServerStateOwner>]
   [<CommonParameters>]

Description

This cmdlet adds additional Access Services database servers to host Access Services databases.

Examples

Example 1

PS C:\>New-SPAccessServicesDatabaseServer -ServiceContext http://siteUrl -DatabaseServerName SQLSVR01 -ValidateServer:$true

This example adds the SQL Server named SQLSVR01 as an Access Services database server using the context of the site, http://siteUrl. This also validates SQLSVR01 is capable of hosting Access Services databases.

Required Parameters

-DatabaseServerName

Specifies the name of the SQL Server to add.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-ServiceContext

Specifies the service context to retrieve Access Services information from.

Type:SPServiceContextPipeBind
Position:0
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016

Optional Parameters

-AssignmentCollection

Manages objects for the purpose of proper disposal. Use of objects, such as SPWeb or SPSite, can use large amounts of memory and use of these objects in Windows PowerShell scripts requires proper memory management. Using the SPAssignment object, you can assign objects to a variable and dispose of the objects after they are needed to free up memory. When SPWeb, SPSite, or SPSiteAdministration objects are used, the objects are automatically disposed of if an assignment collection or the Global parameter is not used.

When the Global parameter is used, all objects are contained in the global store. If objects are not immediately used, or disposed of by using the Stop-SPAssignment command, an out-of-memory scenario can occur.

Type:SPAssignmentCollection
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-AvailableForCreate

Indicates whether or not the SQL Server is available to create Access Services databases on. The default value is true.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-DatabaseServerCredentials

Specifies the credentials used to connect to the SQL Server.

Type:PSCredential
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-DatabaseServerGroupName

Specifies the Access Services database group name. The default value is DEFAULT.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-Encrypt

Specifies to use SSL encryption between Access Services and the SQL Server hosting Access Services databases.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-Exclusive

If the SQL Server has AvaliableForCreate set to False, this will update it to True. If the SQL Server Id does not match the database server Id and the server has AvailableForCreate set to True, this will set AvailableForCreate to False.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-LoginType

Indicates the login type. Valid values are:

  • ApplicationLogin

*LocalDBApplicationLogin

  • ServerLogin

  • StorageAccountLogon

  • WindowsAzureServerLogin

The default value is ServerLogin.

Type:LoginType
Parameter Sets:ApplicationLogin, LocalDBApplicationLogin, ServerLogin, StorageAccountLogon, WindowsAzureServerLogin
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016
-SecondaryDatabaseServerName

Specifies a secondary SQL Server to associate to the new SQL Server. This is used for disaster recovery purposes.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-ServerReferenceId

Provide a specific Server Reference Id. By default, a Server Reference Id is generated automatically when the SQL Server is added.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-State

Indicates the availability of the SQL Server to be added. Valid values are:

  • Active

  • Locked

  • Reserved

The default value is Active.

Type:DatabaseServerStates
Parameter Sets:Active, Locked, Reserved
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016
-StateOwner

Specifies the state owner. Valid values are:

  • NoOwner

  • TenantMove

The default value is NoOwner.

Type:ServerStateOwner
Parameter Sets:NoOwner, TenantMove
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2016
-TrustServerCertificate

Sets a value that indicates whether the channel will be encrypted while bypassing walking the certificate chain to validate trust.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-UserDomain

Specifies the domain to use for credentials.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-ValidateServer

Validates the SQL Server is in a supported state to host Access Services databases.

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016
-WhatIf

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

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016

Inputs

Microsoft.SharePoint.PowerShell.SPServiceContextPipeBind

Microsoft.SharePoint.PowerShell.SPAssignmentCollection

Outputs

System.Object