Answers.Body: <p>Turns out that Craft's search indexes were corrupted.  After rebuilding the search indexes, that damn tag was correctly showing up.</p>
  
  <p>Hope this helps anyone that might have had just content gone mysteriously MIA.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T00:34:51.220Z
Answers.LastActivityDate: 2016-04-13T00:34:51.220Z
Answers.UserDisplayName: biko
Answers.Body: <p>You don't need to use the search parameter in this case. I'd avoid using it where ever possible.</p>
  
  <pre><code>{% set tag = craft.tags.slug(slug).first() %}
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T06:14:32.397Z
Answers.Text: I tried that as well with no luck.  It's odd because this isn't a search query.  Not really sure what was happening behind the scenes, but thanks for posting this.
Answers.UserDisplayName: biko
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T06:17:14.320Z
Answers.Text: Also I'm not sure whether tags.slug() works.  slug() works with entries though.  https://craftcms.com/docs/templating/craft.tags
Answers.UserDisplayName: biko
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T06:31:40.333Z
Answers.Text: It's missing in the documentation, but it should work (it's there in the db table and I'd also used it with success). So yes, odd indeed. Do you have a field with handle "query", because that's what `query:slug` does, see the table of [searching syntaxes](https://craftcms.com/docs/searching).
Answers.UserDisplayName: carlcs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T06:34:30.960Z
Answers.Text: Also, what's the error you're seeing with this approach? Because I just noticed you didn't use `first` in your question to get just one tag, so it returns an array.
Answers.UserDisplayName: carlcs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-16T23:39:33.707Z
Answers.Text: My apologies.  Your query does work!  I was using the first() method somewhere further down the code because I was testing the length of the array first.  Your query didn't work before because first() was being executed twice.  Thanks @carlcs!
Answers.UserDisplayName: biko
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-17T06:00:35.093Z
Answers.Text: No worries, I'm glad you got it resolved.
Answers.UserDisplayName: carlcs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-04-13T01:00:13.427Z
Answers.LastActivityDate: 2016-04-13T01:00:13.427Z
Answers.UserDisplayName: carlcs
Body: <p>Weird issue where a tag was not found using the tags search query.  That tag is in the CMS (in news entries) as well as the DB, and even shows up in other queries.  Query in question:</p>
  
  <pre><code>{%
      set tag = craft.tags({
          search: { query: slug }
      }).limit(1)
  %}
  </code></pre>
  
  <p>All but this tag can't be found for some odd ghostly reason.</p>
  
Tags: <search><tags><queries>
Title: Tag mysteriously not found
ThreadText: # Tag mysteriously not found
  
  (Asked by: username_0 on 2016-04-13)
  
  Weird issue where a tag was not found using the tags search query. That tag is in the CMS (in news entries) as well as the DB, and even shows up in other queries. Query in question:
  
  ```
  {%
      set tag = craft.tags({
          search: { query: slug }
      }).limit(1)
  %}
  
  ```
  
  All but this tag can't be found for some odd ghostly reason.
  
  **Tags:** search, tags, queries
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_0 on 2016-04-13. Score: 2 | Accepted answer
  
  Turns out that Craft's search indexes were corrupted. After rebuilding the search indexes, that damn tag was correctly showing up.
  
  Hope this helps anyone that might have had just content gone mysteriously MIA.
  
  
  ---
  
  ### Answer by username_1 on 2016-04-13. Score: 3
  
  You don't need to use the search parameter in this case. I'd avoid using it where ever possible.
  
  ```
  {% set tag = craft.tags.slug(slug).first() %}
  
  ```
  
  > **Comments:**
  > **username_0**: I tried that as well with no luck.  It's odd because this isn't a search query.  Not really sure what was happening behind the scenes, but thanks for posting this.  
  > **username_0**: Also I'm not sure whether tags.slug() works.  slug() works with entries though.  https://craftcms.com/docs/templating/craft.tags  
  > **username_1**: It's missing in the documentation, but it should work (it's there in the db table and I'd also used it with success). So yes, odd indeed. Do you have a field with handle "query", because that's what `query:slug` does, see the table of [searching syntaxes](https://craftcms.com/docs/searching).  
  > **username_1**: Also, what's the error you're seeing with this approach? Because I just noticed you didn't use `first` in your question to get just one tag, so it returns an array.  
  > **username_0**: My apologies.  Your query does work!  I was using the first() method somewhere further down the code because I was testing the length of the array first.  Your query didn't work before because first() was being executed twice.  Thanks @username_1!  
  > **username_1**: No worries, I'm glad you got it resolved.  
  
  ---
  
  