Azure / Azure/azure-powershell

An error will occur without the optional parameter "-ResourceGroupName" in the Get-AzEffectiveRouteTable syntax.

Open
#16,153 6 comments 0 reactions 0 assignees View on GitHub
act-quality-productivity-squad customer-reported Network question Service Attention
Dominant language
C#
Stars
4.8k
Forks
4.3k
Avg merge
2d 17h
Merged PRs (30d)
51

Description

## Description
In the Get-AzEffectiveRouteTable [documentation](https://docs.microsoft.com/en-us/powershell/module/az.network/get-azeffectiveroutetable?view=azps-6.5.0) and Get-help content, "-ResourceGroupName" is not required but an optional parameter (\[-ResourceGroupName\]), but when I run the command that get the error "Get-AzEffectiveRouteTable: 'resourceGroupName' cannot be null.".

I would like you to correct that the parameter "-ResourceGroupName" is required.

## Steps to reproduce

```powershell
Get-AzEffectiveRouteTable -NetworkInterfaceName ""
```

## Environment data

```
Name Value
---- -----
PSVersion 7.1.5
PSEdition Core
GitCommitId 7.1.5
OS Microsoft Windows 10.0.19043
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
```

## Module versions

```powershell
ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Script 6.5.0 Az
Script 4.12.0 Az.Network {Add-AzApplicationGatewayAuthenticationCertificat…
```

## Error output

```
Get-AzEffectiveRouteTable: 'resourceGroupName' cannot be null.
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.