No default service level objective found of edition "GeneralPurpose"

Hi all I got this issue while deploying my .net web application into Azure . In my application I was creating the Database by EnityFramework Code first approach . So after deploying the application to azure ,I changed the connection string . Then when I run my application , I see this error message "No default service level objective found of edition"GeneralPurpose".
 This was my connection string.

<connectionStrings>
        <add name="CodeFirstDataBase" connectionString="Data Source=tcp:mysite.database.windows.net,1437;Initial Catalog=SchoolCodeFirstDB; User ID=testn;Password=admin;Integrated Security=false;MultipleActiveResultSets=True;App=EntityFramework;" providerName="System.Data.EntityClient" />
 </connectionStrings>

So I investigated a lot but could not get a exact solution for it . But this fix worked for me .

I just changed  the connection string provide name from providerName="System.Data.EntityClient" to  providerName="System.Data.SqlClient" and it worked fine for me .


So this would be the resulted connection string .
<connectionStrings>
        <add name="CodeFirstDataBase" connectionString="Data Source=tcp:mysite.database.windows.net,1437;Initial Catalog=SchoolCodeFirstDB; User ID=testn;Password=admin;Integrated Security=false;MultipleActiveResultSets=True;App=EntityFramework;" providerName="System.Data.SqlClient" />
 </connectionStrings>

Please share your comments please .

Comments

Popular posts from this blog

The transaction is aborted or Failure while attempting to promote transaction.

The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.

Unable to load one or more breakpoints in Visual studio.