title: Cannot open database "MyDb" requested by the login. The login failed. Login failed for user 'My-PC\\MrD'
body: <p>I have been connecting to my local database (SQL Express) fine all day from my C# console application.</p>
  
  <p>I have made an update, where I create a database and table from within the C# code using ADO.NET </p>
  
  <p>When I do this, my normal connection string fails, which is</p>
  
  <pre><code>    Data Source=.\\sqlexpress;  Trusted_Connection=True;  Initial Catalog=ThisIsMyDataBase;
  </code></pre>
  
  <p>The error message is</p>
  
  <pre><code>Cannot open database "ThisIsMyDataBase" requested by the login. The login failed.\r\nLogin failed for user 'My-PC\\MrD'.
  </code></pre>
  
  <p>If I open the tables in SSMS, then I can access everything, using Windows Authentication.</p>
  
  <p>I was under the impression that the <code>Trusted_Connection=True</code> would mean I have permission, and that I'm accessing it with my Windows account (not an SQL account) would mean I don't see this issue, but I'm clearly wrong. I'm not sure how to solve this.</p>