title: How to connect mysql database in .Net
body: <p>I am new to .Net, in which I have written a controller such that is</p>
  
  <pre><code> public class StudentController : Controller
  {        
      public ActionResult Index()
      {
          return View();
      }
  }
  </code></pre>
  
  <p>And a model class like following</p>
  
  <pre><code>public class Students
  {
  
      public int id{ get; set;}
      public String name{ get; set; }
      public int age{ get; set; }
  
  }
  </code></pre>
  
  <p>And I have created a table named student in mysql database. Now I want to get the data from the table, but I don't know how to connect to a mysql DB in .Net </p>
  
  <p>Please anybody help with some example code</p>