37
votes
Accepted
User ID and Account ID: What do they refer to?
user_id is the Id of the user on the specific site. For example, my user id on Stack Overflow is 189134. However, my user id on Community Building is 78.
The account_id, is the way to link these two ...
AndyMod
- 50.3k
36
votes
Stack Overflow is no longer providing Creative Commons Data Dumps
So on my tirade against AI on Meta Stack Exchange, I did a little extra digging around about what was and wasn't kosher with respect to LLM training.
In short, IANAL but I don't think that the CEO's ...
27
votes
User ID and Account ID: What do they refer to?
The Id is the user's ID on that particular site. The AccountId is their user ID for the network profile, which can be plugged into stackexchange.com/users/{id} and get to a user's network profile ...
23
votes
Accepted
How many new users start off asking good questions?
39.2% on 2022-07-03, out of 4.582m first posts.
This does not include deleted posts (only the first post non-deleted post). It does not include users who did not post at all. It only counts first ...
21
votes
Stack Overflow is no longer providing Creative Commons Data Dumps
The same concern was brought up on the network-wide Meta site: June 2023 Data Dump is missing. Although I have answered there, I have also copied my answer here for maximum visibility:
Much has been ...
14
votes
Accepted
What is the meaning of Views attribute in the file Users.xml in the Stack Overflow data dump?
In your user profile, there's a 'x profile views' field. That would be the Views attribute you're searching for.
13
votes
How can I get Stack Overflow datasets related to comment ending with .csv?
If you don't want to download the datadump and don't want to fiddle with T-SQL in SEDE you can download about 500,000 comments in one go with this query. The query makes use of the PIVOT statement to ...
12
votes
How to extract all questions from Stack Overflow?
Stack Overflow controversially changed the way you obtain the Data Dump. Dumps are no longer being uploaded to the Internet Archive and the last official upload was in April 2024 containing data up ...
9
votes
How can I get Stack Overflow datasets related to comment ending with .csv?
As an alternative to data dumps, you can use the Stack Exchange Data Explorer (aka SEDE). Although due to sheer number of comments on Stack Overflow, such a query is going to be slow due to the ...
8
votes
How can I get Stack Overflow datasets related to comment ending with .csv?
Stack Exchange in general runs data dumps that are available for public consumption (list of all dumps can be found here). In particular, SO (due to the site's size) breaks data dumps into separate ...
MachavityMod
- 31.4k
8
votes
Accepted
It appears that the DeletionDate column in the Stack Exchange data dumps available on archive.org is always empty
The Posts table (and subsequently the Posts.xml) doesn't have deleted posts, so DeletionDate will always be null.
In the SEDE instance you'll find a table PostsWithDeleted and that table does have ...
7
votes
Accepted
How to collect question text before and after an edit - for recommending a suggestion when a user posts a question
If you have found PostHistory.xml you already have everything you need.
The initial body revision will be the rows with posthistorytypeid = 2 and any subsequent revision will be posthistorytypeid = ...
6
votes
Accepted
Searching by vote type (not by score)
Use the data explorer, for example this query.
select top 1000
postid as [Post Link]
, sum(case when votetypeid = 2 then 1 else 0 end) [upvotes]
, sum(case when votetypeid = 3 then 1 else 0 end) [...
6
votes
Accepted
How can I get the categorized reputation of a user into different tags?
The following pivot query does that for you.
Notice that I didn't do a full/correct reputation calc, just the bits based on voting and neglecting any reputation cap, offered bounties, accepted ...
6
votes
Are deleted comments included in the data dump?
Deleted comments are not present in the Datadump nor in SEDE. You can, of course, find comments that are deleted today but weren't at the time the dump was created.
Both SEDE and the Datadump are ...
5
votes
How to collect question text before and after an edit - for recommending a suggestion when a user posts a question
You're looking for the post's revision history. The URLs for those are https://stackoverflow.com/posts/<POST ID>/revisions, and the link to them is found on any post which has been edited in the ...
5
votes
How to download the answers to my questions on Stack Overflow
Add an extra join on the posts table and join on acceptedanswerid, like so:
DECLARE @UserId int = ##MyAccountID:int?3632206##
SELECT Posts.Tags,Posts.Title,Posts.Body, acc.body [accepted answer]
FROM ...
4
votes
Accepted
Developer Jobs Data Archive Availability?
At the moment, it's not something we're making publicly available (and I'm not aware of any plans in that direction).
4
votes
Is it possible for users to generate a dump of their questions/answers?
I quickly created this query for you.
It simply does a union over posts, comments and edit posthistory where you're the owner. SEDE does have an export to CSV option so you click that and have a local/...
3
votes
What is the meaning of Posts.Id and how I look the corresponding post from https://www.stackoverflow.com?
There is nothing wrong with your approach. The id found in the Posts.xml belongs to the question (or answer) id found in the url of your browser.
You don't even have to worry about if the id of the ...
3
votes
Obtaining related questions for the data dump
The table PostLinks is available in both SEDE and the data-dump. This is its schema as found in Database schema documentation for the public data dump and SEDE :
PostLinks
Id primary key
CreationDate ...
2
votes
Can we add an auxiliary 'numbers' table to the SEDE?
Each site has its own database. That database is recreated from scratch every Sunday. There is one extra common database (called Data), but that one holds critical system data, including users. The ...
2
votes
Download Stack Overflow database
Note that you can use Google BigQuery to query the quarterly dumps too.
Announcement:
https://medium.com/google-cloud/google-bigquery-public-datasets-now-include-stack-overflow-q-a-5a8a7e371b52
For ...
1
vote
Get activity over time for a specific question
This is already possible (and easy) with existing tools like /posts/<questionid>/timeline. Thanks y'all!
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
data-dump × 29support × 18
discussion × 8
data-explorer × 8
feature-request × 4
search × 2
statistics × 2
stack-exchange × 2
api × 2
site-analytics × 2
research × 2
data × 2
status-completed × 1
tags × 1
comments × 1
voting × 1
deleted-questions × 1
new-users × 1
status-norepro × 1
views × 1
licensing × 1
related-questions × 1
personal-data × 1
first-questions × 1
legacy-stack-overflow-jobs × 1