5

After creating a query to figure out the close reason for a question at http://data.stackexchange.com/codereview/query/edit/489136 I notice that the close reason type is listed multiple times.

To figure out the close reason I followed the https://meta.stackexchange.com/a/2678/244032 documentation and more specifically the PostHistory table with PostHistoryTypeId = 10, yet I get two entries for the close reason type whereas I would expect only a single close reason.

Take https://codereview.stackexchange.com/questions/128975/generating-a-balanced-binary-tree as example question, in my SEDE query it gets two entries, one with CloseReasonType = 103 and the other with CloseReasonType = 102, both cast by user Jamal, meaning "Unclear what you're asking" and "Off-topic" respectively.

Now my question is: How do I figure out the close reason that is listed on the question? In the example question it is listed as "put on hold as off-topic by Jamal♦ 19 hours ago" and the mentioning of "Unclear what you're asking" is completely gone.

6

Check the post's timeline, it has two close reasons because it's been closed twice.

It was first closed as unclear what you're asking then reopened and closed again as off-topic all by Jamal who as a site moderator can do that singlehandedly.

The close reason displayed on the post will be the one with the latest CreationDate entry where the PostHistoryTypeId = 10 Something like this perhaps

You must log in to answer this question.

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