title: EF4 CTP5 Code First approach ignores Table attributes
body: <p>I'm using EF4 CTP5 code first approach but am having trouble getting it to work. I have a class called "Company" and a database table called "CompanyTable". I want to map the Company class to the CompanyTable table, so have code like this:</p>
  
  <pre><code>[Table(Name = "CompanyTable")]
      public class Company
      {
          [Key]
          [Column(Name = "CompanyIdNumber", DbType = "int")]
          public int CompanyNumber { get; set; }
  
          [Column(Name = "CompanyName", DbType = "varchar")]
          public string CompanyName { get; set; }
      }
  </code></pre>
  
  <p>I then call it like so:</p>
  
  <pre><code>var db = new Users();
              var companies = (from c in db.Companies
                              select c).ToList();
  </code></pre>
  
  <p>However it errors out:</p>
  
  <p><strong>Invalid object name 'dbo.Companies'.</strong></p>
  
  <p>It's obviously not respecting the Table attribute on the class, even though it says <a href="http://blogs.msdn.com/b/adonet/archive/2010/12/06/ef-feature-ctp5-code-first-walkthrough.aspx" rel="nofollow">here</a> that Table attribute is supported. Also it's pluralizing the name it's searching for (Companies instead of Company.) How do I map the class to the table name?</p>