title: CAML query contains does not work
body: <p>I've got this code, which takes a part of the title to perform a query and filter part of the content of a list:</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  
  var items_lista; 
  
      SP.SOD.executeFunc('sp.js', 'SP.ClientContext', Initialize);
  
      function Initialize() {
  
          var PDP_Link_Filter = $("title").text().split("-")[1].split(".")[0];  
  
          PDP_Link_Filter = "Link_" + PDP_Link_Filter + "_"; 
  
          var contexto = SP.ClientContext.get_current();
          var web = contexto.get_web();
          var listas = web.get_lists();
          var parametros = listas.getByTitle('Parametrizacion_WF');
  
          var query = new SP.CamlQuery();
  
          query.set_viewXml("&lt;Query&gt;&lt;Where&gt;&lt;Contains&gt;&lt;FieldRef Name='Title'/&gt;" + 
                            "&lt;Value Type='Text'&gt;" + PDP_Link_Filter + "&lt;/Value&gt;&lt;/Contains&gt;&lt;/Where&gt;&lt;/Query&gt;");
  
          console.log(query);
  
          items_lista = parametros.getItems(query);
          contexto.load(items_lista);
          contexto.executeQueryAsync(Function.createDelegate(this, this.onRequestSucceeded), Function.createDelegate(this, this.onRequestFailed));
  
      } //Initialize 
  
      function onRequestSucceeded() 
      {
          console.log(items_lista); 
          for(i = 0; i &lt; items_lista.get_count(); i++) 
          {
              console.log(items_lista.get_item(i).get_item('Title'));
          }       
      }
      function onRequestFailed() { console.log('Error'); }
  
  &lt;/script&gt;
  </code></pre>
  
  <p>The query filter that it generates (obtained through console.log()):</p>
  
  <pre><code>&lt;Query&gt;&lt;Where&gt;&lt;Contains&gt;&lt;FieldRef Name='Title'/&gt;&lt;Value Type='Text'&gt;P000&lt;/Value&gt;&lt;/Contains&gt;&lt;/Where&gt;&lt;/Query&gt;
  </code></pre>
  
  <p>But when the for loop runs it shows all the content of the list not just the rows that match the filter. </p>
  
  <p>What am I doing wrong?</p>