title: how to remove arraylist value in elastic search using curl?
body: <p>How to remove arraylist values in Elasticsearch using sense console or curl?</p>
  
  <p>i want to remove any array element.?</p>
  
  <pre><code>POST /q/q/
  {
      "a": [
      "z", "q", "1"
      ]
  }
  </code></pre>
  
  <p>it doesnt work for me:</p>
  
  <pre><code>POST /q/q/AV4sjk40mWHLgYFNkmNd/_update
  {
      "script": {
          "lang": "painless",
          "inline": "ctx._source.a -=newsupp",
          "params": {
              "newsupp": "p" 
          }
       }
  }
  </code></pre>
  
  <p>or</p>
  
  <pre><code>POST /q/q/AV4sjk40mWHLgYFNkmNd/_update
  {
      "script": {
          "lang": "painless",
          "inline": "ctx._source.a.remove("1")"
      }
  }
  </code></pre>