title: Renaming the duplicate data in sql
body: <p>I am able to find out the duplicate data using this query</p>
  
  <pre><code>   SELECT names FROM group GROUP BY names HAVING count(*) &gt; 1
  </code></pre>
  
  <p>I am able to get the duplicate data.I just need to know how to rename this duplicate data with the name to <strong>new</strong></p>
  
  <pre><code>  INPUT
  +-----------------+               
  | names           |
  +-----------------+
  | text1           |
  | text2           |
  | text3           |
  | text1           |
  | text3           |
  | text4           |
  +-----------------+
  
  OUTPUT  
  +-----------------+
  | names           |
  +-----------------+ 
  | text1           |
  | text2           |
  | text3           |
  | text1 new value |-&gt;RENAMED
  | text3 new value |-&gt;RENAMED
  | text4           |
  +-----------------+
  </code></pre>