New-AzureSqlDatabaseServerFirewallRule

[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

New-AzureSqlDatabaseServerFirewallRule

Creates a new firewall rule in the specified SQL Database server in the current subscription.

Syntax

Parameter Set: IpRange
New-AzureSqlDatabaseServerFirewallRule [-ServerName] <String> -EndIpAddress <String> -RuleName <String> -StartIpAddress <String> [-Force] [-Confirm] [-WhatIf] [ <CommonParameters>]

Detailed Description

The New-AzureSqlDatabaseServerFirewallRule cmdlet creates a new firewall rule in the specified SQL Database server. Any IP address within the range specified in the StartIpAddress and EndIpAddress parameters will be able to connect to the SQL Database server. A firewall rule with starting and ending IP addresses equal to 0.0.0.0 indicates that Windows Azure connections to this SQL Database server are allowed.

Parameters

-EndIpAddress<String>

End value of the IP address range.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Force

Allows the action to complete without prompting you for confirmation.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RuleName<String>

New SQL Database firewall rule name.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ServerName<String>

The name of the SQL Database server where the new firewall rule is created. Specify only the server name, and not the fully qualified DNS name.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-StartIpAddress<String>

Start value of the IP address range.

Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before executing the command.

Required?

false

Position?

named

Default Value

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

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.

Outputs

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

  • SqlDatabaseServerFirewallRuleContext

Examples

-------------- Example 1 --------------

This command creates a new firewall rule (“myRule”) in the specified SQL Database server (“lpqd0zbr8y”).

PS C:\> New-AzureSqlDatabaseServerFirewallRule –ServerName "lpqd0zbr8y" -RuleName "myRule" -StartIpAddress 12.1.1.1 –EndIpAddress 12.1.1.2

Get-AzureSqlDatabaseServerFirewallRule

Remove-AzureSqlDatabaseServerFirewallRule

Set-AzureSqlDatabaseServerFirewallRule