title: Data Annotation table columns
body: <pre><code>public partial class Employee
  {     
      public int Emp_Id { get; set; }
      public string Emp_Name { get; set; }
      public string Emp_City { get; set; }
      public Nullable&lt;int&gt; Emp_Age { get; set; }
  }
  </code></pre>
  
  <p>This is generated class for table <code>Employee</code> using EF. I want <code>Emp_Name</code> change to <code>EmpName</code> in application without changing table structure. But using below changes using data annotation <code>dbEntity.Set&lt;Employee&gt;().ToList();</code>  getting exception</p>
  
  <blockquote>
    <p>"The entity type Employee is not part of the model for the current
    context."</p>
    
    <p>System.InvalidOperationException.</p>
  </blockquote>
  
  <p>How can solve this</p>
  
  <pre><code>public partial class Employee
  { 
      public int Emp_Id { get; set; }
      [Column("Emp_Name")]
      public string EmpName { get; set; }
      public string Emp_City { get; set; }
      public Nullable&lt;int&gt; Emp_Age { get; set; }
  }
  </code></pre>