title: Postgres append multiple elements to an array
body: <p>I have the following table in postgres with the below schema</p>
  
  <pre><code>Relations 
  
  | id | tags |
  </code></pre>
  
  <p>I need to update the field tags to append unique multiple elements to it
  I can very well achieve it with like the below</p>
  
  <pre><code>for (String tagId : tagIds ) {
  
      // Execute the below query in PostGRES
      UPDATE Relations SET tags = array_append (array_remove (tags, '" + tagId + "'), '" + tagId + "') WHERE id = '" + id + "'";
  
  }
  </code></pre>
  
  <p>But I want to append an array of elements to it in a single go without the for loop. Can someone let me know the query for that ?</p>