连接字符串在Web主机服务器中的_之后跳过用户标识

时间:2015-10-15 13:57:35

标签: asp.net sql-server deployment connection-string

我已经将我的网站部署到运行Plesk和ASP.NET企业管理器的Web托管。我创建了一个用户myapp_user2并将其分配给mydatabase_db1,但是当我运行我的网站时,我只能看到它在underscore

之后跳过用户名的错误

错误:

Cannot open database "mydatabase_db1" requested by the login. The login failed.
Login failed for user 'W1\IWPD_271(myapp)'.

<connectionStrings>
  <add name="myappDBContext" connectionString="metadata=res://*/Areas.ADMIN.Models.Model.csdl|res://*/Areas.ADMIN.Models.Model.ssdl|res://*/Areas.ADMIN.Models.Model.msl;provider=System.Data.SqlClient;provider connection string=&quot;data source=.\MSSQLSERVER2012;initial catalog=mydatabase_db1;integrated security=True;MultipleActiveResultSets=True;User ID=myapp_user2;Password='123345';App=EntityFramework&quot;" providerName="System.Data.EntityClient" />
</connectionStrings>

1 个答案:

答案 0 :(得分:1)

删除integrated security = True以使用连接字符串中的用户ID