Web api working locally but not when deployed to Azure
<p>I have a Web Api that I have developed which works perfectly fine when run locally, but when I publish it on Azure, I get a <code>500 Internal Sever Error</code>.</p>

<p>I have 3 tables in the Database - "Messages", "Users", "Conversations"</p>

<p>The error only happens when I make a call to "Conversations" or "Users".
(Conversations contains a list of Users and Users contains a list of conversations.)</p>

<p>I am not sure what is causing this and I don't know how to get more information from this error.</p>

<p>I have tried changing the entity framework connection string, although I didn't really know what I was doing with it. The other connection strings in my web.config seem to be fine. </p>

<p>Is this a database problem or a code first problem? </p>

<p>Web.confg:</p>

<pre><code>&lt;connectionStrings&gt;
&lt;add name="DefaultConnection" connectionString="Data Source=tcp:uqq5j22p7m.database.windows.net,1433;Initial Catalog=AA_db;Persist Security Info=True;User ID=KENH@uqq5j22p7m;Password=Password;Connect Timeout=30;Encrypt=True;MultipleActiveResultSets=True;"
  providerName="System.Data.SqlClient" /&gt;
&lt;add name="AcademicAssistantContext" connectionString="Data Source=tcp:uqq5j22p7m.database.windows.net,1433;Initial Catalog=AA_db;Persist Security Info=True;User ID=KENH@uqq5j22p7m;Password=Password;Connect Timeout=30;Encrypt=True;MultipleActiveResultSets=True;" 
  providerName="System.Data.SqlClient" /&gt;
</code></pre>

<p></p>

<pre><code>&lt;entityFramework&gt;
&lt;defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework"&gt;
  &lt;parameters&gt;
    &lt;parameter value="Data Source=.; Integrated Security=True; MultipleActiveResultSets=True" /&gt;
  &lt;/parameters&gt;
&lt;/defaultConnectionFactory&gt;
&lt;providers&gt;
  &lt;provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" /&gt;
&lt;/providers&gt;
</code></pre>

<p></p>