title: Elasticsearch Wildcard Query not matching special characters with whitespace analyzer
body: <p>I have an index which is using a whitespace analyzer - see below:</p>
  <pre><code>    {
    &quot;my-index&quot;: {
      &quot;settings&quot;: {
        &quot;index&quot;: {
          &quot;number_of_shards&quot;: &quot;15&quot;,
          &quot;provided_name&quot;: &quot;my-index&quot;,
          &quot;creation_date&quot;: &quot;1638550619099&quot;,
          &quot;analysis&quot;: {
            &quot;normalizer&quot;: {
              &quot;lowercase_normalizer&quot;: {
                &quot;filter&quot;: [
                  &quot;lowercase&quot;,
                  &quot;asciifolding&quot;
                ],
                &quot;type&quot;: &quot;custom&quot;,
                &quot;char_filter&quot;: []
              }
            },
            &quot;analyzer&quot;: {
              &quot;my_analyzer&quot;: {
                &quot;filter&quot;: [
                  &quot;lowercase&quot;
                ],
                &quot;char_filter&quot;: [],
                &quot;tokenizer&quot;: &quot;whitespace&quot;
              }
            }
          },
          &quot;number_of_replicas&quot;: &quot;1&quot;,
          &quot;uuid&quot;: &quot;WrteqKeaTwuGGEXOpckwQw&quot;,
          &quot;version&quot;: {
            &quot;created&quot;: &quot;7090199&quot;
          }
        }
      }
    }
  }
  </code></pre>
  <p>I can confirm the analyzer outputs as expected for text with special characters:</p>
  <pre><code>!curl -X GET &quot;https://xxx/my-index/_analyze?pretty&quot; -H &quot;Content-Type: application/json&quot; -d'{&quot;analyzer&quot;: &quot;my_analyzer&quot;,&quot;text&quot; : [&quot;This - is - an item&quot;]}'
  </code></pre>
  <blockquote>
  <blockquote>
  </blockquote>
  </blockquote>
  <pre><code>{
    &quot;tokens&quot; : [
      {
        &quot;token&quot; : &quot;This&quot;,
        &quot;start_offset&quot; : 0,
        &quot;end_offset&quot; : 4,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 0
      },
      {
        &quot;token&quot; : &quot;-&quot;,
        &quot;start_offset&quot; : 5,
        &quot;end_offset&quot; : 6,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 1
      },
      {
        &quot;token&quot; : &quot;is&quot;,
        &quot;start_offset&quot; : 7,
        &quot;end_offset&quot; : 9,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 2
      },
      {
        &quot;token&quot; : &quot;-&quot;,
        &quot;start_offset&quot; : 10,
        &quot;end_offset&quot; : 11,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 3
      },
      {
        &quot;token&quot; : &quot;an&quot;,
        &quot;start_offset&quot; : 12,
        &quot;end_offset&quot; : 14,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 4
      },
      {
        &quot;token&quot; : &quot;item&quot;,
        &quot;start_offset&quot; : 15,
        &quot;end_offset&quot; : 19,
        &quot;type&quot; : &quot;word&quot;,
        &quot;position&quot; : 5
      }
    ]
  }
  </code></pre>
  <p>However, when specifying a wildcard query with a special character, in this case &quot;-&quot;, I'm unable to get any results back</p>
  <pre><code>    my_query = {
      &quot;query&quot;: {
         &quot;bool&quot;:{
            &quot;must&quot;:[
               {
                  &quot;wildcard&quot;:{
                     &quot;ec_item_name&quot;:{
                        &quot;value&quot;:&quot;-*&quot;
                     }
                  }
               }
            ]
         }
      }
  }
  </code></pre>
  <p>I understand that wildcard queries are not analyzed, but I am not understanding how this could apply here anyway. If the whitespace analyzer is specified at index time and is identifying &quot;-&quot; as a word, how is the wildcard query unable to match? It doesn't seem to be a problem for alphanumeric values</p>