96

Sometimes I can best remember a question by its comments. How can I search for a question that way?

Downloading the data dump is not viable because it may be a question posted today.

8
  • 1
    Very true. Much of what I recall is based on other users' comments, not my own. Using the accepted answer below, http://www.google.co.uk/search?q=site:superuser.com+version*+Lion+awesome+developer did find what I want, but it took me a few minutes to figure this out. IMHO it would be much neater to allow searches from within Stack Exchange, or from within a particular stack. Not a default; an advanced search option. Aug 5, 2011 at 13:29
  • Here is a feature-request that covers this. Jan 7, 2013 at 14:19
  • I feel your pain.
    – superuser
    Jan 13, 2013 at 5:40
  • For comments which are less than a week old go to activity tab -> comments. Here you can see all your comment ordered by latest first. So you can easily search latest comments. For older commnets you can search them from the data-explorer. See this answer
    – Himanshu
    Apr 24, 2014 at 9:26
  • 2
    @hims056 Not my comments, other users' comments.
    – RedFilter
    Apr 24, 2014 at 17:15
  • this may help data.stackexchange.com/meta.stackexchange/query/151786/…
    – barlop
    Jul 22, 2016 at 14:11
  • @HimanshuJansari - where is the activity tag?
    – Sam
    Jun 27, 2021 at 13:47
  • 1
    @Sam: Activity tab is available about user's profile picture. Where you can switch between 'Profile' and 'Activity'. You can now check the comments from Activity > All actions > Comments.
    – Himanshu
    Jun 28, 2021 at 4:49

5 Answers 5

36

Since the top five comments of each post are displayed in the page, Google indexing can pick them up. So if you can remember key words from the comments, a Google search (with site:stackoverflow.com, of course) should be able to find them.

For example, I know I once made a comment with the phrase "four-year-old". I can use this search to find it again (the second link shows my name in the preview, so it's a pretty good bet).

6
  • 1
    So that was YOU. I remember that comment! I'll be damned if I can remember the question though...
    – RedFilter
    Oct 1, 2009 at 20:23
  • I want to search for people spamming but Google returns non-spam comments that are spam.
    – clickbait
    Jun 21, 2015 at 16:03
  • @mmyers, What does "top five comments of each post" mean? "top" as ordered by votes followed by post date? Does this work only for questions or does this work for every answer too?
    – Pacerier
    Feb 28, 2016 at 15:25
  • @Pacerier: I mean whichever comments are shown by default. The rules have changed a few times in the past. (And the question I referred to in this answer has long since been deleted.)
    – mmyers
    Feb 29, 2016 at 16:42
  • I can't find this comment in Google: stackoverflow.com/questions/29614171/… using a search like this one: google.com/… May 8, 2016 at 9:16
  • Scratch that - it works now. Guess it can take Google's crawler a while. May 18, 2016 at 9:10
55

You can't at the moment. It's annoying to me, too.

6
  • 77
    Its ok, we should ask the guys that make this site to... wait a minute...
    – perbert
    Sep 28, 2009 at 23:19
  • Why would anybody want to search for comments?
    – Tom
    Jun 21, 2010 at 21:00
  • 23
    @Tom: I was just awarded the "Pundit" badge, which apparently means 10 of my comments have been upvoted 10 times. I'm quite interested to see which ones they are! (Yes I'm vain :-P) Oct 3, 2010 at 10:29
  • 5
    @Tom I would like to search for all my comments with '-1' to see whether they should stay that way, or if I was in a foul mood that day. Some times I leave comments I mean to be temporary and I tag them with some text; I may have forgot about some. Apr 13, 2013 at 21:17
  • 2
    @j_random_hacker try this. And upvote this answer (and its question) for I took the link from there. :)
    – Sufian
    Aug 27, 2016 at 17:40
  • 13 years later, any update? ;-) Dec 5, 2022 at 9:06
9

It won't help with other people's comments, but for your own comments to questions posted today, click your name at the top of the page to get to your profile page and then click on the "recent" tab near the middle of the page. This should show comments for the last couple days or so.

Additionally, to search older comments you don't have to download the entire data dump. Just use http://data.stackexchange.com

8

The Stack Exchange Data Explorer lets you avoid downloading the complete data dump. Here is such a query; feel free to fork it to adapt it to your needs. It's able to find this question by a part of the first comment:

enter image description here

Note that SEDE is updated only once a week, on Sunday morning.

1
  • Side note you need to escape the 3 special characters of SQL LIKE query if you want to search for them. See this example query for an example
    – user202729
    Jul 10, 2022 at 6:22
0

You can use in your profile activity tab with comments tag.

1
  • 5
    Useful (I did this a few times), but not when seeking other people's comments. Aug 5, 2011 at 13:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .