Failed to shut down. The supplied SqlConnection does not specify a start directory or AttachDBFileName

I am trying to create an App App web application on the Azure portal and connect the web application to a local local SQL Server database using the new Hybrid Connection feature.

I created a simple ASP.NET application using Visual Studio 2015 and tried to connect to the SQL Server database, which is at a preliminary stage. And changed the connection string as follows

<connectionStrings> <add name="DefaultConnection" connectionString="Data Source=PRAVEEN,1433; User ID=sa; Password=my_password;" providerName="System.Data.SqlClient" /> </connectionStrings> 

When the application starts without any errors, as shown in the figure below.

But when I try to register (enter any entry), it throws me an error, as indicated in the screenshot below 3 ....

" https://azure.microsoft.com/en-us/documentation/articles/web-sites-hybrid-connection-connect-on-premises-sql-server/ " is the documentation to which I mean ..

So can anyone from the other end help me please ...

Screenshot1

ScreenShot2

Screenshot3

Screenshot of Microsoft SQL Server Management Studio ....

Microsoft Sql Server Management Studio

Thanks..

+7
sql-server sql-server-2014-express visual-studio-2015 azure
source share
1 answer

@Praveen, This is what he says - it means that your connection directory does not have a start directory. This requires the name Db. You have a server name, SQLUserName, SQLPassword, but there is no DatabaseName that is required. Please change the connection string to include the name DbName as follows

 <connectionStrings> <add name="DefaultConnection" connectionString="Data Source=YourServerName,1433;Database="YourDbName" UserID=YourId;Password=YourPswd;" providerName="System.Data.SqlClient" /> </connectionStrings> 

Look at this site to properly configure the connection string: http://www.connectionstrings.com/store-connection-string-in-webconfig/

+3
source share

All Articles