I am trying to connect an Azure SQL DB resource using the app id of an already registered application in Azure. I am using entity framework database first approach.
3
-
1What's the issue you are facing?Chetan– Chetan2019-07-08 10:14:33 +00:00Commented Jul 8, 2019 at 10:14
-
U need to follow the same steps as normal sql server. You will give credentials of Azure while giving connectionstring. Thats it.sri harsha– sri harsha2019-07-08 10:16:44 +00:00Commented Jul 8, 2019 at 10:16
-
Hi Vijay Kulkarni, If my answer is helpful for you, you can accept it as answer( click on the check mark beside the answer to toggle it from greyed out to filled in.). This can be beneficial to other community members. Thank you.Leon Yue– Leon Yue2019-07-11 01:40:52 +00:00Commented Jul 11, 2019 at 1:40
Add a comment
|
2 Answers
Since you have an c# Azure web APP, please reference this document: Quickstart: Use .NET Core (C#) to query an Azure SQL database.
In this quickstart, you'll use .NET Core and C# code to connect to an Azure SQL database. You'll then run a Transact-SQL statement to query data.
Hope this helps.
Comments
There are a few steps to connecting to the Azure SQL database. I suggest reading this article
You will need to:
- Add your IP to the Azure SQL firewall
- Create a login via SQL management studio
Once you've completed the above you'll be able to update the connection string in your application's web.config to establish a connection.