title: What is the best way to remove duplicates from a datatable?
body: <p>I have checked the whole site and googled on the net but was unable to find a simple solution to this problem.</p>
  
  <p>I have a datatable which has about 20 columns and 10K rows. I need to remove the duplicate rows in this datatable based on 4 key columns. Doesn't .Net have a function which does this? The function closest to what I am looking for was datatable.DefaultView.ToTable(true, array of columns to display), But this function does a distinct on <strong>all</strong> the columns.</p>
  
  <p>It would be great if someone could help me with this.</p>
  
  <p>EDIT: I am sorry for not being clear on this. This datatable is being created by reading a  CSV file and not from a DB. So using an SQL query is not an option.</p>