Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Azure by (13.1k points)

When trying to connect to Azure SQL database with my free trail account. It is throwing this error.

com.microsoft.sqlserver.jdbc.SQLServerException: Cannot open server 'ccaausprddb001' requested by the login. Client with IP address '125.16.236.150' is not allowed to access the server.  To enable access, use the Windows Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.

Can anyone help me who to set rules for this?

1 Answer

0 votes
by (26.7k points)

The following error can be solved by configuring the firewall of Azure SQL Server. And to do that, these are the following steps you need to follow:

1. Select your SQL Server.

2. Click the Settings -> Firewall

3. After that you will be requested Add a new Rule.

4. Add a name and enter the IP address(or the range) that will access the database. note: Azure automatically detects your current IP. 

Once it has been done, wait for sometimes and you are good to go.

I hope this will work.

Want to become an Azure Expert? join Azure Training now!!

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...