Twitter Search Ignores Underscore '_' when Searching Username - Therefore, results are distorted when username is two words separated by underscore

siegerts
@siegerts Stephen Siegert

Hi -

If a one word username (i.e. twitterapi) is searched, the resulting set could be:
1) A tweet originating from said author
2) A tweet mentioning that author (i.e. @twitterapi)
3) A tweet with a hashtag reference of that author (i.e. #twitterapi)
4) A Tweet that contains the author's handle in the body text

----BUT----

If a username is searched that contains and underscore then the underscore is treated as a space in the query string. Therefore, "nikerun_jp" becomes "nikerun jp" completely distorting the search results. Omitted results include:

1) A tweet originating from said author
2) A tweet mentioning that author (i.e. @nikerun_jp)
3) A tweet with a hashtag reference of that author (i.e. #nikerun_jp)
4) The exact match of the author's handle in the tweet

Therefore, in order to capture all of the results for a username search that contains an underscore one query must be broken out to contain a search for:
1) @nikerun_jp
2) #nikerun_jp
3) "nikerun jp" <---- aka "nikerun" & "jp"

and even then the exact match "nikerun_jp" is not returned by the search...

Please advise on any possible fix for the search mechanism or workaround solution for the underscore problem...

Thank You in Advance,
Stephen

2 years 17 weeks ago

Replies

The_Qwerty
@The_Qwerty Randy

Yep... searching for my username has been utterly useless the last couple of weeks.

The frustrating part is nothing is done to prune inactive usernames unless it's trademarked, and the official support documents suggest adding underscores when your desired username is not available, however they make no mention of the fact that search won't return meaningful results if the query contains an underscore.

I think the best that can presently be done is to search for from, to, or mentioning: "from:The_Qwerty OR to:The_Qwerty OR @The_Qwerty"

Would be nice if Twitter, Feedback, Support, or twitterpi would at least acknowledge whether this change is a bug or part of an initiative to decrease the number meaningful results from a query.

2 years 16 weeks ago
trprdubstep
@trprdubstep Carl Bastard

This is surely something that must be adressed soon?

2 years 15 weeks ago
davidaustria
@davidaustria David Austria

I have the same problem with the search: from:equilibrio_

2 years 15 weeks ago
episod
@episod Taylor Singletary

Hi all, we're working to resolve this but it will take a few steps. Expect the full resolution sometime next week.

2 years 15 weeks ago
siegerts
@siegerts Stephen Siegert

Great! Thanks, Taylor!

2 years 15 weeks ago
InnovDigital
@InnovDigital Innovation Digital

Hi there,

We are also experiencing this with one of our clients @Edinburgh_.

Would be grateful if you could let us know when this is fixed.

Thanks

Andrew Weddle (Innovation Digital)

2 years 15 weeks ago
Jebs_Helper
@Jebs_Helper Jeb&#039;s Helper

Hi, I recently came opun this topic when one of my friends sent it to me. I am called Jebs_Helper because I help someone named @jeb_ with their mentions. I can't do this anymore, because of how the searching works. You could use the same code as Google when searching, and have spaces be a "+" in the URL bar and not an "". Because if I search @jeb to see his mentions, I mainly only get mentions from @jeb. Again, my suggestion is above.

Thanks if you read this twitter....
@Jebs_Helper

2 years 14 weeks ago
Jebs_Helper
@Jebs_Helper Jeb&#039;s Helper

Strange.... The underscore only worked once... I meant to have an underscore the first time it says @jeb (not @jeb[underscore), and in the empty quotation marks.

2 years 14 weeks ago
InnovDigital
@InnovDigital Innovation Digital

Hi Taylor, do we have any idea when this issue maybe resolved? Just an indicative 'we've no idea what's going on, argh' or 'we've got a handle on it, give it a couple of days' would suffice otherwise we're going to have to alter our code to consume the results.

Thanks

Andrew Weddle

2 years 14 weeks ago
episod
@episod Taylor Singletary

The first part of this issue should be resolved:

The second part of this issue will be resolved within the next week or two:

  • searching for users with underscores in the username through: users/search

If there's another aspect to this bug that I'm not aware of, please describe clearly with examples of executed API URLs and how the response doesn't jive with what you're expecting. Thanks!

2 years 14 weeks ago
siegerts
@siegerts Stephen Siegert

Hi Taylor,

What about searching usernames as search terms (w/o "@") through search.twitter.com without specifying "from:"?

For example,

http://search.twitter.com/search.json?q=jaguarusa&rpp=100 will return tweets FROM @JaguarUSA without the need to specify "from:"

but

http://search.twitter.com/search.json?q=roi_media&rpp=100 does not return tweets from @ROI_Media unless the query is rewritten to include "OR from:ROI_Media" .

The underscore is still omitted when a username is treated as a search term resulting in the AND logic to occur for the terms separated by the underscore.

Thanks,
Stephen

2 years 14 weeks ago
InnovDigital
@InnovDigital Innovation Digital

Hi Taylor,

Still getting no results from this query :

http://search.twitter.com/search.json?q=from%3AEdinburgh_

Thanks

Andrew Weddle

2 years 14 weeks ago
episod
@episod Taylor Singletary

Thanks, I'll let the team know there are still some failing cases.

2 years 14 weeks ago
martinkl
@martinkl Martin Kleppmann

Hey Taylor, do you have any news on this? I'm also still having problems with trailing underscores: e.g. http://search.twitter.com/search.json?q=from:radian_&rpp=3 returns results for user @radian instead of @radian_

Thanks, Martin

2 years 13 weeks ago
DanielaValero_
@DanielaValero_ Daniela

Hello, Seems the problem with searches like " from:useraname_ " doesn't be solved yet, please keep us posted

2 years 14 weeks ago
edinburgh_
@edinburgh_ Inspiring Edinburgh

Still getting no results from this query http://search.twitter.com/search.json?q=from%3AEdinburgh_

Also searching Twitter using Hootsuite for @edinburgh_ only produces results for @edinburgh

Any news on when this will be fixed?

2 years 13 weeks ago
episod
@episod Taylor Singletary

No update yet when this will be fixed. Will continue working on getting this prioritized.

2 years 13 weeks ago
InnovDigital
@InnovDigital Innovation Digital

Any update on this please? Getting a bit desperate now.....

Thanks

Andrew

2 years 12 weeks ago
Space_Jon
@Space_Jon @jondcarroll

as am I ... is there a planned fix for this, pls ?

2 years 7 weeks ago
c4rl
@c4rl Carl Wiedemann

This is still not working for some cases. http://search.twitter.com/search.json?q=from%3ACGNet_Swara

2 years 7 weeks ago
kurrik
@kurrik Arne Roomann-Kurrik

That user's Tweets are well outside of the search index range, which is only 6-9 days.

2 years 7 weeks ago
c4rl
@c4rl Carl Wiedemann

You are incorrect. https://skitch.com/c4rl/8g1s7/tweet-timestamps

2 years 7 weeks ago
episod
@episod Taylor Singletary

This account's non-appearance in search results is due to a reason other than the underscore in its name -- you'll need to follow up with Twitter @support on this: https://support.twitter.com/articles/66018-i-m-missing-from-search

2 years 7 weeks ago
c4rl
@c4rl Carl Wiedemann

I've submitted a support request and am awaiting a reply. Thanks.

2 years 7 weeks ago
kurrik
@kurrik Arne Roomann-Kurrik

Right you are, sorry, copy and paste error on my part.

2 years 7 weeks ago
steffenschmidt
@steffenschmidt Steffen Schmidt

Searching for see_conference finds results (third result) that are not in desired:
http://search.twitter.com/search.json?q=see_conference

1 year 51 weeks ago
episod
@episod Taylor Singletary

Which specific tweet didn't belong?

1 year 51 weeks ago
steffenschmidt
@steffenschmidt Steffen Schmidt

The tweet with ID 194743100512542720…

1 year 51 weeks ago
colorcrate
@colorcrate Ian Hamilton

Running into this error myself using RSS search... http://search.twitter.com/search.rss?q=elife_sciences&rpp=5 fails to find tweets from the user @elife_sciences

1 year 49 weeks ago
tradingSkool
@tradingSkool tradingSkool.com

Hi Taylor,

My "Profile" and "Search" widgets on my site have been down for almost a month. The codes are originated from Twitter and they have been working fine.

Kindly visit www.tradingskool.com

Is there any resolutions?

Thanks.

1 year 42 weeks ago
episod
@episod Taylor Singletary

It looks like you're trying to display a profile widget for a protected account -- protected accounts can't be shared publicly so there's nothing for the widget to display.

1 year 42 weeks ago
s81mss
@s81mss sante

Hi,

I have the same problem with this request:
http://search.twitter.com/search.atom?q=from:kikomakeup_de

about this profile: https://twitter.com/kikomakeup_de.

What should I do? Can you check it?

Thanks

1 year 28 weeks ago
episod
@episod Taylor Singletary

This doesn't appear to be a bug with the underscore -- it's just that @kikomakeup_de doesn't appear to be indexed by search.

Why are the Tweets I'm looking for not in Twitter Search, the Search API, or Search widgets?

Twitter's search is optimized to serve relevant tweets to end-users in response to direct, non-recurring queries such as #hashtags, URLs, domains, and keywords. The Search API (which also powers Twitter's search widget) is an interface to this search engine. Our search service is not meant to be an exhaustive archive of public tweets and not all tweets are indexed or returned. Some results are refined to better combat spam and increase relevance. Due to capacity constraints, the index currently only covers about a week's worth of tweets.

The user timeline API is the definitive source of tweets by a specific author. For a collection of recent Tweets by more than one user, consider creating a Twitter List and leveraging the list timeline. The Streaming API is often the best-fit choice when seeking completeness.

If the tweets you're looking for aren't available in search and you think they should be, consult this support topic for further instructions to contact @Support.

1 year 28 weeks ago
MothTwiceborn
@MothTwiceborn Robert Ramsay

I'm trying to exclude a user Tinyfish_ from my searches for Tinyfish and having no luck thanks to this problem. Please can you fix it.

1 year 25 weeks ago