I\'m initializing Entity Framework Object context, and this gives me the keyword not supported error:
metadata=res://*/MainDB.csdl|res://*/MainDB.ssdl|res://*/
Just use \" instead ", it should resolve the issue.
I fixed this by changing EntityClient
back to SqlClient
, even though I was using Entity Framework.
So my complete connection string was in the format:
<add name="DefaultConnection" connectionString="Data Source=localhost;Initial Catalog=xxx;Persist Security Info=True;User ID=xxx;Password=xxx" providerName="System.Data.SqlClient" />
The real reason you were getting this error is because of the "
values in your connection string.
If you replace those with single quotes then it will work fine.
https://docs.microsoft.com/archive/blogs/rickandy/explicit-connection-string-for-ef
(Posted so others can get the fix faster than I did.)
Believe it or not, renaming LinqPad.exe.config to LinqPad.config solved this problem.
This appears to be missing the providerName="System.Data.EntityClient"
bit. Sure you got the whole thing?
Make sure you have Data Source
and not DataSource
in your connection string. The space is important. Trust me. I'm an idiot.