7
$\begingroup$

How can I search for closed questions that have been answered by a particular user?

$\endgroup$
7
  • $\begingroup$ Can we not search going to the concerned profile using the relevant tags? $\endgroup$ Feb 22, 2023 at 8:54
  • $\begingroup$ @User1865345, what about including the condition that the question must be closed? $\endgroup$ Feb 22, 2023 at 9:09
  • $\begingroup$ I have searched your profile for closed posts. Is this the solution? Perhaps not. But I am experimenting a bit. $\endgroup$ Feb 22, 2023 at 9:14
  • $\begingroup$ @User1865345, this only finds my questions that have been closed. It does not find my answers to questions that have been closed. I am looking for the latter. $\endgroup$ Feb 22, 2023 at 9:15
  • $\begingroup$ Hm. What I found is this Maths post where they wrote a query for the same. You can check it. But as of whether a particular user's answer can be found out, I couldn't find any useful stuff so far. There is closed:yes answers:1... but this of course doesn't do the job. $\endgroup$ Feb 22, 2023 at 9:34
  • $\begingroup$ Yes, that query plausibly works. $\endgroup$ Feb 22, 2023 at 9:45
  • $\begingroup$ One wrinkle is that deleted questions are only visible for users with at least 10,000 reputation. Under certain criteria, closed questions are automatically deleted, so this might be relevant. $\endgroup$
    – Sycorax Mod
    Feb 22, 2023 at 14:49

3 Answers 3

5
$\begingroup$

I found this script Answers to closed questions for user

But there is a line that prevents all results from showing up

questions.ClosedDate < answers.CreationDate

I edited it into this script and it seems to work.

$\endgroup$
2
  • $\begingroup$ This seems to work! Would it be possible to use the search window on Cross Validated to achieve that? $\endgroup$ Feb 22, 2023 at 9:43
  • 2
    $\begingroup$ The search uses an inner join of two selections from the posts table. I don't believe that the search window is able to do that. It seems to only perform a single query of the type 'select ... from ... where ...'. $\endgroup$ Feb 22, 2023 at 9:57
3
$\begingroup$

https://stats.stackexchange.com/search?q=user%3A53690+is%3Aanswer+closed%3Ayes

enter image description here

For details, please consult the search help page.

To find a user's identifying number, look them up on the Users page.

$\endgroup$
5
  • 1
    $\begingroup$ Whuber, does it return the answers to the questions closed? It only returns the questions that were closed. After all, there are no "closed" answers. $\endgroup$ Feb 22, 2023 at 13:57
  • $\begingroup$ @User1865345 As always, it links to them all. If you want more flexibility, then use the Data Explorer. $\endgroup$
    – whuber Mod
    Feb 22, 2023 at 13:58
  • $\begingroup$ This only seems to return questions by user X that were closed. I am looking for answers by user X of questions that were closed. $\endgroup$ Feb 22, 2023 at 15:07
  • 1
    $\begingroup$ Relevant Meta SO post: Cannot search for answers on closed questions. $\endgroup$ Feb 22, 2023 at 15:22
  • 2
    $\begingroup$ That is indeed confusing. Thank you for the clarification. The Meta post found by @User1865345 offers an explanation. $\endgroup$
    – whuber Mod
    Feb 22, 2023 at 16:42
3
$\begingroup$

Apart from Sextus Empiricus' script, the query provided at Maths Meta post also essentially caters to your requirements. Here is the link to the script: basically it orders the posts as per the scores.

$\endgroup$
1
  • 1
    $\begingroup$ Thanks! That seems to work. $\endgroup$ Feb 22, 2023 at 16:12

You must log in to answer this question.

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