Java remove duplicate values from result set
<p>I have requirement to remove the duplicate values from result set based on some unique identifier.</p>

<p>I need to remove the duplicates from the result set.</p>

<pre><code>  while(resultSet.next())
  {     
   int seqNo = resultSet.getInt("SEQUENCE_NO");

   String tableName = resultSet.getString("TABLE_NAME");

   String columnName = resultSet.getString("COLUMN_NAME");

  String filter = resultSet.getString("FILTER");

 }
</code></pre>

<p>from the above iteration, i m getting 2 rows from result set. There is same seq no,same table name, different columnname, same filter.</p>

<pre><code>1 PRODUCTFEES CHARGETYPE PRODUCTID

1 PRODUCTFEES PRODUCTCODE PRODUCTID
</code></pre>

<p>My requirement is to remove the duplicate table name, duplicate seq no, duplicate filter.</p>

<p>I want to get output something below,</p>

<pre><code>1 PRODUCTFEES CHARGETYPE PRODUCTCODE PRODUCTID
</code></pre>

<p>Please help me as its very important for me and near by deadline.</p>

<p>Thanks.</p>
