title: Using SQL Server CE 4 on a remote host with MVC 3
body: <p>I just upgraded my host to MVC 3 but I'm trying to do a &quot;hello world&quot; using SQLCE 4.0 but I just got:</p>
  <blockquote>
  <p>Sorry, an error occurred while
  processing your request.</p>
  </blockquote>
  <p>I see my layout and everything but instead of data I see that.</p>
  <p>On localhost is working as expected</p>
  <p>I have:</p>
  <pre><code>&lt;add name=&quot;PruebaContext&quot; connectionString=&quot;Data Source=|DataDirectory|db.sdf&quot; providerName=&quot;System.Data.SqlServerCE.4.0&quot;/&gt;
  </code></pre>
  <p>as connectionString.</p>
  <p>I put the sdf as part of the project, I added the <strong>System.Data.SqlServerCE.dll</strong> to the project with the <em>local copy</em> to true.</p>
  <p>I have no more ideas. The connString, the dll is in /bin and is working in localhost.</p>
  <p>Any ideas?</p>
  <p>Thanks.</p>
  <p><strong>EDIT</strong></p>
  <p>I have some logs now:</p>
  <p>Without the &quot;System.Data.SqlServerCE.dll&quot; on /bin:</p>
  <blockquote>
  <p>Unable to find the requested .Net Framework Data Provider.  It may not be installed.</p>
  <p>System.ArgumentException: Unable to find the requested .Net Framework Data Provider.  It may not be installed.</p>
  </blockquote>
  <p>Fine enough. They don't have SqlServerCE4.</p>
  <p>With the Dll on local copy, AKA /bin:</p>
  <blockquote>
  <p>Unable to load the native components of SQL Server Compact corresponding to the ADO.NET provider of version 8482. Install the correct version of SQL Server Compact. Refer to KB article 974247 for more details.</p>
  <p>Exception Details: System.Data.SqlServerCe.SqlCeException: Unable to load the native components of SQL Server Compact corresponding to the ADO.NET provider of version 8482. Install the correct version of SQL Server Compact. Refer to KB article 974247 for more details.</p>
  </blockquote>
  <p>The KB says that I need the dll from x86 and amd64. I read somewhere that if I copy two directories to /bin, like: /bin/x86 and /bin/amd64 . I copied that folders from the private folder of SqlServerCE 4 installation folder. Now I got:</p>
  <blockquote>
  <p>Possible file version mismatch detected between ADO.NET Provider and native binaries of SQL Server Compact which could result in an incorrect functionality. This could be due to the presence of multiple instances of SQL Server Compact of different versions or due to wrong binaries with same name as SQL Server Compact binaries. Please install SQL Server Compact binaries of matching version.</p>
  </blockquote>
  <p>Ok. On the root folder of SQLServerCE4 I have some dlls too, so I deleted that two folders and copied that dll to /bin:</p>
  <blockquote>
  <p>Could not load file or assembly 'file:///C:\HostingSpaces\jesusrod\foxandxss.net\wwwroot\mvc3\bin\sqlceca40.dll' or one of its dependencies. The module was expected to contain an assembly manifest.</p>
  </blockquote>
  <p>I think that I tried all things. Scottgu said that SqlServerCE 4 should work on any server without installation.</p>