Entity Framework - The underlying provider failed on ConnectionString

前端 未结 2 1579
难免孤独
难免孤独 2021-01-17 21:56

While using the Entity Framework I have split it out to it\'s own project:

  • RivWorks.Model - Contains Entity Model
  • RivWorks.Controller - Uses the Entit
相关标签:
2条回答
  • 2021-01-17 22:31

    I know you've been mucking around with your connection strings to sanitize them but I'm guessing you didn't put the "'s around the password in?

    Are they actually required?

    0 讨论(0)
  • 2021-01-17 22:41

    Double check your connection string is correct, little typo's can cause this same error.

    This is wrong:

     <add name="Entities" connectionString="metadata=res://*/OnlineAB.csdl|res://*/OnlineAB.ssdl|res://*/OnlineABSuperAdmin.msl;provider=System.Data.SqlClient;provider connection string=&quot;data source.;initial catalog=
    

    This is right:

     <add name="Entities" connectionString="metadata=res://*/OnlineAB.csdl|res://*/OnlineAB.ssdl|res://*/OnlineABSuperAdmin.msl;provider=System.Data.SqlClient;provider connection string=&quot;data source=.;initial catalog=
    

    See after the DataSource I was missing an equal sign.

    0 讨论(0)
提交回复
热议问题