| author | MikeRayMSFT |
|---|---|
| ms.author | mikeray |
| ms.date | 11/25/2018 |
| ms.service | virtual-machines-sql |
| ms.topic | include |
| ms.custom | devx-track-azurepowershell |
Run the Connect-Az Account cmdlet and you will be presented with a sign-in screen to enter your credentials. Use the same credentials that you use to sign in to the Azure portal.
Connect-AzAccountIf you have multiple subscriptions use the Set-AzContext cmdlet to select which subscription your PowerShell session should use. To see what subscription the current PowerShell session is using, run Get-AzContext. To see all your subscriptions, run Get-AzSubscription.
Set-AzContext -SubscriptionId '4cac86b0-1e56-bbbb-aaaa-000000000000'