db_id stringclasses 11
values | instruction stringlengths 1.63k 14k | role stringclasses 45
values | policy unknown | input stringlengths 23 477 | output stringlengths 23 2.22k | difficulty stringclasses 3
values | metadata dict |
|---|---|---|---|---|---|---|---|
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many badges has the user csgillespie obtained? | SELECT COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.DisplayName = 'csgillespie' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.DisplayName = 'csgillespie'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Please list the names of the badges obtained by csgillespie. | SELECT T1.`Name` FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.DisplayName = 'csgillespie' | simple | {
"gold_sql": "SELECT T1.`Name` FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.DisplayName = 'csgillespie'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Among the badges obtained by csgillespie, how many of them were obtained in the year 2011? | SELECT COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE STRFTIME('%Y', T1.Date) = '2011' AND T2.DisplayName = 'csgillespie' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE STRFTIME('%Y', T1.Date) = '2011' AND T2.DisplayName = 'csgillespie'",
"permission": "allowed",
"query_columns": {
"badges": [
"Date",
"Id",
"UserId"
],
"users": [
"DisplayName... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the display name of the user who has obtained the most number of badges? | SELECT T2.DisplayName FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id GROUP BY T2.Id ORDER BY COUNT(T1.Id) DESC, T2.Id ASC LIMIT 1 | simple | {
"gold_sql": "SELECT T2.DisplayName FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id GROUP BY T2.Id ORDER BY COUNT(T1.Id) DESC, T2.Id ASC LIMIT 1",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the average score of the posts owned by the user csgillespie? | SELECT AVG(T1.Score) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T2.DisplayName = 'csgillespie' | simple | {
"gold_sql": "SELECT AVG(T1.Score) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T2.DisplayName = 'csgillespie'",
"permission": "allowed",
"query_columns": {
"posts": [
"OwnerUserId",
"Score"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_col... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the average number of badges obtained by a user with over 200 views? | SELECT CAST(COUNT(T1.Id) AS REAL) / COUNT(DISTINCT T2.DisplayName) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.Views > 200 | simple | {
"gold_sql": "SELECT CAST(COUNT(T1.Id) AS REAL) / COUNT(DISTINCT T2.DisplayName) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T2.Views > 200",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"UserId"
],
"users": [
"DisplayName",
"Id",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Among the posts with a score of over 5, what is the percentage of them being owned by an elder user? | SELECT CAST(SUM(IIF(T2.Age > 65, 1, 0)) AS REAL) * 100 / COUNT(T1.Id) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T1.Score > 5 | moderate | {
"gold_sql": "SELECT CAST(SUM(IIF(T2.Age > 65, 1, 0)) AS REAL) * 100 / COUNT(T1.Id) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T1.Score > 5",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId",
"Score"
],
"users": [
"Age",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many votes did the user No.58 take on 2010/7/19? | SELECT COUNT(Id) FROM votes WHERE UserId = 58 AND CreationDate = '2010-07-19' | simple | {
"gold_sql": "SELECT COUNT(Id) FROM votes WHERE UserId = 58 AND CreationDate = '2010-07-19'",
"permission": "allowed",
"query_columns": {
"votes": [
"CreationDate",
"Id",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 558,
"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Indicate the creation date of the maximum number of votes. | SELECT CreationDate
FROM votes
GROUP BY CreationDate
ORDER BY COUNT(Id) DESC, CreationDate ASC
LIMIT 1 | simple | {
"gold_sql": "SELECT CreationDate \nFROM votes \nGROUP BY CreationDate \nORDER BY COUNT(Id) DESC, CreationDate ASC \nLIMIT 1",
"permission": "allowed",
"query_columns": {
"votes": [
"CreationDate",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"quest... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Give the number of "Revival" badges. | SELECT COUNT(Id) FROM badges WHERE Name = 'Revival' | simple | {
"gold_sql": "SELECT COUNT(Id) FROM badges WHERE Name = 'Revival'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"Name"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 560,
"evidence": "number refers to Id; 'Revival' is the... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What are the titles of all posts that have comments with the highest score? | SELECT DISTINCT p.Title FROM posts p INNER JOIN comments c ON p.Id = c.PostId WHERE c.Score = (SELECT MAX(Score) FROM comments) ORDER BY p.Title ASC | simple | {
"gold_sql": "SELECT DISTINCT p.Title FROM posts p INNER JOIN comments c ON p.Id = c.PostId WHERE c.Score = (SELECT MAX(Score) FROM comments) ORDER BY p.Title ASC",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Score",
"Title"
],
"comments": [
"PostId",
"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | For the post which got 1910 view counts, how many comments does it get? | SELECT COUNT(T1.Id) FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T1.ViewCount = 1910 | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T1.ViewCount = 1910",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"ViewCount"
],
"comments": [
"PostId"
]
},
"missing_columns": {},
"reason": "All requi... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | User No.3025 gave a comment at 20:29:39 on 2014/4/23 to a post, how many favorite counts did that post get? | SELECT T1.FavoriteCount FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T2.CreationDate = '2014-04-23 20:29:39.0' AND T2.UserId = 3025 | moderate | {
"gold_sql": "SELECT T1.FavoriteCount FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T2.CreationDate = '2014-04-23 20:29:39.0' AND T2.UserId = 3025",
"permission": "allowed",
"query_columns": {
"posts": [
"FavoriteCount",
"Id"
],
"comments": [
"CreationDate",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Give the comment text of the post with only one comment and parent id 107829. | SELECT T2.Text FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T1.ParentId = 107829 AND T1.CommentCount = 1 | simple | {
"gold_sql": "SELECT T2.Text FROM posts AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.PostId WHERE T1.ParentId = 107829 AND T1.CommentCount = 1",
"permission": "allowed",
"query_columns": {
"posts": [
"CommentCount",
"Id",
"ParentId"
],
"comments": [
"PostId",
"Text"
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | User No.23853 gave a comment to a post at 9:08:18 on 2013/7/12, was that post well-finished? | SELECT IIF(T2.ClosedDate IS NULL, 'NOT well-finished', 'well-finished') AS resylt
FROM comments AS T1
INNER JOIN posts AS T2 ON T1.PostId = T2.Id
WHERE T1.UserId = 23853 AND T1.CreationDate = '2013-07-12 09:08:18.0'; | moderate | {
"gold_sql": "SELECT IIF(T2.ClosedDate IS NULL, 'NOT well-finished', 'well-finished') AS resylt\nFROM comments AS T1\nINNER JOIN posts AS T2 ON T1.PostId = T2.Id\nWHERE T1.UserId = 23853 AND T1.CreationDate = '2013-07-12 09:08:18.0';",
"permission": "allowed",
"query_columns": {
"posts": [
"ClosedDate"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | For the owner user of post No. 65041, what is his/her reputation points? | SELECT T1.Reputation FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T2.Id = 65041 | simple | {
"gold_sql": "SELECT T1.Reputation FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T2.Id = 65041",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId"
],
"users": [
"Id",
"Reputation"
]
},
"missing_columns": {},
"reason"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | For the user with the display name of "Tiago Pasqualini", how many posts did he/she own? | SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName = 'Tiago Pasqualini' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName = 'Tiago Pasqualini'",
"permission": "allowed",
"query_columns": {
"posts": [
"OwnerUserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Provide the display name of the user who made the vote No.6347. | SELECT T1.DisplayName FROM users AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.UserId WHERE T2.Id = 6347 | simple | {
"gold_sql": "SELECT T1.DisplayName FROM users AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.UserId WHERE T2.Id = 6347",
"permission": "allowed",
"query_columns": {
"users": [
"DisplayName",
"Id"
],
"votes": [
"Id",
"UserId"
]
},
"missing_columns": {},
"reason": "All re... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Give the number of votes for the post about data visualization. | SELECT COUNT(T1.Id) FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId WHERE T1.Title LIKE '%data visualization%' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId WHERE T1.Title LIKE '%data visualization%'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"votes": [
"PostId"
]
},
"missing_columns": {},
"reason": "Al... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | For the user whose display name is "DatEpicCoderGuyWhoPrograms", what is his/her badge's name? | SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'DatEpicCoderGuyWhoPrograms' | simple | {
"gold_sql": "SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'DatEpicCoderGuyWhoPrograms'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_col... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | For the user No.24, how many times is the number of his/her posts compared to his/her votes? | SELECT
(SELECT CAST(COUNT(*) AS REAL) FROM posts WHERE OwnerUserId = 24) /
(SELECT CAST(COUNT(*) AS REAL) FROM votes WHERE UserId = 24) | moderate | {
"gold_sql": "SELECT \n (SELECT CAST(COUNT(*) AS REAL) FROM posts WHERE OwnerUserId = 24) /\n (SELECT CAST(COUNT(*) AS REAL) FROM votes WHERE UserId = 24)",
"permission": "allowed",
"query_columns": {
"posts": [
"OwnerUserId"
],
"votes": [
"UserId"
]
},
"missing_columns": {}... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many views did the post titled 'Integration of Weka and/or RapidMiner into Informatica PowerCenter/Developer' get? | SELECT ViewCount FROM posts WHERE Title = 'Integration of Weka and/or RapidMiner into Informatica PowerCenter/Developer' | moderate | {
"gold_sql": "SELECT ViewCount FROM posts WHERE Title = 'Integration of Weka and/or RapidMiner into Informatica PowerCenter/Developer'",
"permission": "allowed",
"query_columns": {
"posts": [
"Title",
"ViewCount"
]
},
"missing_columns": {},
"reason": "All required columns are permitted"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Write the contents of comments with a score of 17. | SELECT Text FROM comments WHERE Score = 17 | simple | {
"gold_sql": "SELECT Text FROM comments WHERE Score = 17",
"permission": "allowed",
"query_columns": {
"comments": [
"Score"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 573,
"evidence": "score of 17 refers to Score = 17; contents of comments ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user has the website URL listed at 'http://stackoverflow.com' | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT DisplayName FROM users WHERE WebsiteUrl = 'http://stackoverflow.com'",
"permission": "denied",
"query_columns": {
"users": [
"DisplayName",
"WebsiteUrl"
]
},
"missing_columns": {
"users": [
"WebsiteUrl"
]
},
"reason": "Missing column permissions: use... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the badge name that user 'SilentGhost' obtained? | SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'SilentGhost' | simple | {
"gold_sql": "SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'SilentGhost'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
"r... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Name the user that commented 'thank you user93!' | SELECT T1.DisplayName FROM users AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.UserId WHERE T2.Text = 'thank you user93!' | simple | {
"gold_sql": "SELECT T1.DisplayName FROM users AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.UserId WHERE T2.Text = 'thank you user93!'",
"permission": "allowed",
"query_columns": {
"users": [
"DisplayName",
"Id"
],
"comments": [
"Text",
"UserId"
]
},
"missing_columns"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Write all comments made by user 'A Lion.' | SELECT T2.Text FROM users AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'A Lion' | simple | {
"gold_sql": "SELECT T2.Text FROM users AS T1 INNER JOIN comments AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'A Lion'",
"permission": "allowed",
"query_columns": {
"users": [
"DisplayName",
"Id"
],
"comments": [
"Text",
"UserId"
]
},
"missing_columns": {},
"re... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user made a post titled 'Understanding what Dassault iSight is doing?' and how much is the reputation of the user? | SELECT T1.DisplayName, T1.Reputation FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T2.Title = 'Understanding what Dassault iSight is doing?' | moderate | {
"gold_sql": "SELECT T1.DisplayName, T1.Reputation FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T2.Title = 'Understanding what Dassault iSight is doing?'",
"permission": "allowed",
"query_columns": {
"posts": [
"OwnerUserId",
"Title"
],
"users": [
"Display... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Write all comments made on the post titled 'How does gentle boosting differ from AdaBoost?' | SELECT T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T2.Title = 'How does gentle boosting differ from AdaBoost?' | simple | {
"gold_sql": "SELECT T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T2.Title = 'How does gentle boosting differ from AdaBoost?'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"comments": [
"PostId",
"Text"
]
},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Name 10 users with the badge name 'Necromancer.' | SELECT DISTINCT T1.DisplayName
FROM users AS T1
INNER JOIN badges AS T2 ON T1.Id = T2.UserId
WHERE T2.Name = 'Necromancer'
ORDER BY T1.Id ASC
LIMIT 10; | simple | {
"gold_sql": "SELECT DISTINCT T1.DisplayName\nFROM users AS T1\nINNER JOIN badges AS T2 ON T1.Id = T2.UserId\nWHERE T2.Name = 'Necromancer'\nORDER BY T1.Id ASC\nLIMIT 10;",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"I... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Who is the editor of the post titled 'Open source tools for visualizing multi-dimensional data?' | SELECT T2.DisplayName FROM posts AS T1 INNER JOIN users AS T2 ON T1.LastEditorUserId = T2.Id WHERE T1.Title = 'Open source tools for visualizing multi-dimensional data?' | moderate | {
"gold_sql": "SELECT T2.DisplayName FROM posts AS T1 INNER JOIN users AS T2 ON T1.LastEditorUserId = T2.Id WHERE T1.Title = 'Open source tools for visualizing multi-dimensional data?'",
"permission": "allowed",
"query_columns": {
"posts": [
"LastEditorUserId",
"Title"
],
"users": [
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List the title of posts which were edited by Vebjorn Ljosa. | SELECT T1.Title
FROM posts AS T1
INNER JOIN users AS T2 ON T1.LastEditorUserId = T2.Id
WHERE T2.DisplayName = 'Vebjorn Ljosa'; | simple | {
"gold_sql": "SELECT T1.Title\nFROM posts AS T1\nINNER JOIN users AS T2 ON T1.LastEditorUserId = T2.Id\nWHERE T2.DisplayName = 'Vebjorn Ljosa';",
"permission": "allowed",
"query_columns": {
"posts": [
"LastEditorUserId",
"Title"
],
"users": [
"DisplayName",
"Id"
]
},
"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the total score of the posts edited by Yevgeny and include the user's website URL. | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT SUM(T1.Score), T2.WebsiteUrl FROM posts AS T1 INNER JOIN users AS T2 ON T1.LastEditorUserId = T2.Id WHERE T2.DisplayName = 'Yevgeny' GROUP BY T2.WebsiteUrl",
"permission": "denied",
"query_columns": {
"posts": [
"LastEditorUserId",
"Score"
],
"users": [
"Display... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Write all the comments left by users who edited the post titled 'Why square the difference instead of taking the absolute value in standard deviation?' | SELECT T2.Comment FROM posts AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.PostId WHERE T1.Title = 'Why square the difference instead of taking the absolute value in standard deviation?' | moderate | {
"gold_sql": "SELECT T2.Comment FROM posts AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.PostId WHERE T1.Title = 'Why square the difference instead of taking the absolute value in standard deviation?'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"posthistor... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How much is the total bounty amount of the post titled about 'data' | SELECT SUM(T2.BountyAmount) FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId WHERE T1.Title LIKE '%data%' | simple | {
"gold_sql": "SELECT SUM(T2.BountyAmount) FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId WHERE T1.Title LIKE '%data%'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"votes": [
"BountyAmount",
"PostId"
]
},
"missing_columns": {},... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user added a bounty amount of 50 to the post title mentioning variance? | SELECT T3.DisplayName, T1.Title FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId INNER JOIN users AS T3 ON T3.Id = T2.UserId WHERE T2.BountyAmount = 50 AND T1.Title LIKE '%variance%' | challenging | {
"gold_sql": "SELECT T3.DisplayName, T1.Title FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId INNER JOIN users AS T3 ON T3.Id = T2.UserId WHERE T2.BountyAmount = 50 AND T1.Title LIKE '%variance%'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"users... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Calculate the average view count of each post tagged as 'humor' and list the title and the comment of each post. | SELECT AVG(T2.ViewCount), T2.Title, T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T2.Id = T1.PostId WHERE T2.Tags = '<humor>' GROUP BY T2.Title, T1.Text | moderate | {
"gold_sql": "SELECT AVG(T2.ViewCount), T2.Title, T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T2.Id = T1.PostId WHERE T2.Tags = '<humor>' GROUP BY T2.Title, T1.Text ",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Tags",
"Title",
"ViewCount"
],
"comm... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Give the total number of comments posted by user ID 13. | SELECT COUNT(Id) FROM comments WHERE UserId = 13 | simple | {
"gold_sql": "SELECT COUNT(Id) FROM comments WHERE UserId = 13",
"permission": "allowed",
"query_columns": {
"comments": [
"Id",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 588,
"evidence": ""
} |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user ID has the highest reputation? | SELECT Id FROM users WHERE Reputation = ( SELECT MAX(Reputation) FROM users ) | simple | {
"gold_sql": "SELECT Id FROM users WHERE Reputation = ( SELECT MAX(Reputation) FROM users )",
"permission": "allowed",
"query_columns": {
"users": [
"Id",
"Reputation"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 589,
"evidence": "highes... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user ID has the lowest view? | SELECT Id FROM users WHERE Views = ( SELECT MIN(Views) FROM users ) ORDER BY Id ASC | simple | {
"gold_sql": "SELECT Id FROM users WHERE Views = ( SELECT MIN(Views) FROM users ) ORDER BY Id ASC",
"permission": "allowed",
"query_columns": {
"users": [
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 590,
"evidence": ""
} |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users are awarded with supporter badge during year 2011? | SELECT COUNT(DISTINCT UserId)
FROM badges
WHERE STRFTIME('%Y', Date) = '2011'
AND Name = 'Supporter'
AND UserId IS NOT NULL | simple | {
"gold_sql": "SELECT COUNT(DISTINCT UserId) \nFROM badges \nWHERE STRFTIME('%Y', Date) = '2011' \nAND Name = 'Supporter'\nAND UserId IS NOT NULL",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are per... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users are awarded with more than 5 badges? | SELECT COUNT(UserId) FROM ( SELECT UserId, COUNT(Name) AS num FROM badges GROUP BY UserId ) T WHERE T.num > 5 | simple | {
"gold_sql": "SELECT COUNT(UserId) FROM ( SELECT UserId, COUNT(Name) AS num FROM badges GROUP BY UserId ) T WHERE T.num > 5",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users from New York have a teacher and supporter badge? | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT COUNT(*)\nFROM users AS U\nWHERE U.Location = 'New York'\n AND EXISTS (\n SELECT 1 FROM badges AS B1 \n WHERE B1.UserId = U.Id AND B1.Name = 'Supporter'\n )\n AND EXISTS (\n SELECT 1 FROM badges AS B2 \n WHERE B2.UserId = U.Id AND B2.Name = 'Teacher'\n )",
"permission": "denied... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user created post ID 1 and what is the reputation of this user? | SELECT u.DisplayName, u.Reputation
FROM posts AS p
INNER JOIN users AS u ON p.OwnerUserId = u.Id
WHERE p.Id = 1; | simple | {
"gold_sql": "SELECT u.DisplayName, u.Reputation\nFROM posts AS p\nINNER JOIN users AS u ON p.OwnerUserId = u.Id\nWHERE p.Id = 1;",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId"
],
"users": [
"DisplayName",
"Id",
"Reputation"
]
},
"mi... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which users have used only one post history type across all posts having at least 1000 views? | SELECT T2.UserId FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T3.ViewCount >= 1000 GROUP BY T2.UserId HAVING COUNT(DISTINCT T2.PostHistoryTypeId) = 1 | moderate | {
"gold_sql": "SELECT T2.UserId FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T3.ViewCount >= 1000 GROUP BY T2.UserId HAVING COUNT(DISTINCT T2.PostHistoryTypeId) = 1",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which user has posted the most comments? List out all the user's badge. | WITH TopComment AS (SELECT UserId FROM comments GROUP BY UserId ORDER BY COUNT(*) DESC LIMIT 1) SELECT B.Name FROM badges B JOIN TopComment TC ON B.UserId = TC.UserId; | simple | {
"gold_sql": "WITH TopComment AS (SELECT UserId FROM comments GROUP BY UserId ORDER BY COUNT(*) DESC LIMIT 1) SELECT B.Name FROM badges B JOIN TopComment TC ON B.UserId = TC.UserId;",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"comments": []
},
"missin... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users from India have the teacher badges? | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT COUNT(T1.Id)\nFROM badges AS T1\nINNER JOIN users AS T2 ON T1.UserId = T2.Id\nWHERE T2.Location = 'India' AND T1.Name = 'Teacher';",
"permission": "denied",
"query_columns": {
"badges": [
"Id",
"Name",
"UserId"
],
"users": [
"Id",
"Location"
]
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the percentage difference of student badges given during 2010 and 2011? | SELECT CAST(SUM(IIF(STRFTIME('%Y', Date) = '2010', 1, 0)) AS REAL) * 100 / COUNT(Id) - CAST(SUM(IIF(STRFTIME('%Y', Date) = '2011', 1, 0)) AS REAL) * 100 / COUNT(Id) FROM badges WHERE Name = 'Student' | challenging | {
"gold_sql": "SELECT CAST(SUM(IIF(STRFTIME('%Y', Date) = '2010', 1, 0)) AS REAL) * 100 / COUNT(Id) - CAST(SUM(IIF(STRFTIME('%Y', Date) = '2011', 1, 0)) AS REAL) * 100 / COUNT(Id) FROM badges WHERE Name = 'Student'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"Name"
]
},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What are the post history type IDs for post ID 3720 and how many unique users have commented on the post? | SELECT T1.PostHistoryTypeId,
(SELECT COUNT(DISTINCT UserId) FROM comments WHERE PostId = 3720) AS NumberOfUsers
FROM postHistory AS T1
WHERE T1.PostId = 3720; | simple | {
"gold_sql": "SELECT T1.PostHistoryTypeId,\n (SELECT COUNT(DISTINCT UserId) FROM comments WHERE PostId = 3720) AS NumberOfUsers\nFROM postHistory AS T1\nWHERE T1.PostId = 3720;",
"permission": "allowed",
"query_columns": {
"posthistory": [
"PostHistoryTypeId",
"PostId",
"UserId"
]... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List out all post that are related to post ID 61217 and what is the popularity of this post? | SELECT DISTINCT p.Id, p.Title, p.ViewCount
FROM postLinks AS pl
INNER JOIN posts AS p ON p.Id = pl.RelatedPostId
WHERE pl.PostId = 61217; | simple | {
"gold_sql": "SELECT DISTINCT p.Id, p.Title, p.ViewCount\nFROM postLinks AS pl\nINNER JOIN posts AS p ON p.Id = pl.RelatedPostId\nWHERE pl.PostId = 61217;",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title",
"ViewCount"
],
"postlinks": [
"PostId",
"Rel... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the score and the link type ID for post ID 395? | SELECT T1.Score, T2.LinkTypeId FROM posts AS T1 INNER JOIN postLinks AS T2 ON T1.Id = T2.PostId WHERE T2.PostId = 395 | simple | {
"gold_sql": "SELECT T1.Score, T2.LinkTypeId FROM posts AS T1 INNER JOIN postLinks AS T2 ON T1.Id = T2.PostId WHERE T2.PostId = 395",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Score"
],
"postlinks": [
"LinkTypeId",
"PostId"
]
},
"missing_columns": {... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List out all post ID with score more than 60 and list out all the user ID that created these post. | SELECT PostId, UserId FROM postHistory WHERE PostId IN ( SELECT Id FROM posts WHERE Score > 60 ) | simple | {
"gold_sql": "SELECT PostId, UserId FROM postHistory WHERE PostId IN ( SELECT Id FROM posts WHERE Score > 60 )",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Score"
],
"posthistory": [
"PostId",
"UserId"
]
},
"missing_columns": {},
"reason": "All req... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the sum of favourite count gained by user ID 686 in 2011? | SELECT SUM(DISTINCT FavoriteCount)
FROM posts
WHERE Id IN (
SELECT PostId
FROM postHistory
WHERE UserId = 686 AND STRFTIME('%Y', CreationDate) = '2011'
); | simple | {
"gold_sql": "SELECT SUM(DISTINCT FavoriteCount)\nFROM posts\nWHERE Id IN (\n SELECT PostId\n FROM postHistory\n WHERE UserId = 686 AND STRFTIME('%Y', CreationDate) = '2011'\n);",
"permission": "allowed",
"query_columns": {
"posts": [
"FavoriteCount",
"Id"
],
"posthistory": [
"Cr... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the average of the up votes and the average user age for users creating more than 10 posts? | SELECT AVG(T1.UpVotes), AVG(T1.Age) FROM users AS T1 INNER JOIN ( SELECT OwnerUserId, COUNT(*) AS post_count FROM posts GROUP BY OwnerUserId HAVING post_count > 10) AS T2 ON T1.Id = T2.OwnerUserId | moderate | {
"gold_sql": "SELECT AVG(T1.UpVotes), AVG(T1.Age) FROM users AS T1 INNER JOIN ( SELECT OwnerUserId, COUNT(*) AS post_count FROM posts GROUP BY OwnerUserId HAVING post_count > 10) AS T2 ON T1.Id = T2.OwnerUserId",
"permission": "allowed",
"query_columns": {
"posts": [
"OwnerUserId"
],
"users": [... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users obtained the "Announcer" badge? | SELECT COUNT(id) FROM badges WHERE Name = 'Announcer' | simple | {
"gold_sql": "SELECT COUNT(id) FROM badges WHERE Name = 'Announcer'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"Name"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 605,
"evidence": "\"Announcer\" is the Name of badge;... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List out the name of badges that users obtained on 7/19/2010 7:39:08 PM. | SELECT DISTINCT Name FROM badges WHERE Date = '2010-07-19 19:39:08.0' | simple | {
"gold_sql": "SELECT DISTINCT Name FROM badges WHERE Date = '2010-07-19 19:39:08.0'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 606,
"evidence": "on 7/19/2010 7:39:08 PM refers ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many positive comments are there on the list? | SELECT COUNT(id) FROM comments WHERE score > 60 | simple | {
"gold_sql": "SELECT COUNT(id) FROM comments WHERE score > 60",
"permission": "allowed",
"query_columns": {
"comments": [
"Id",
"Score"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 607,
"evidence": "Positive comment refers to score > 60"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | State the detailed content of the comment which was created on 7/19/2010 7:25:47 PM. | SELECT Text FROM comments WHERE CreationDate = '2010-07-19 19:16:14.0' | simple | {
"gold_sql": "SELECT Text FROM comments WHERE CreationDate = '2010-07-19 19:16:14.0'",
"permission": "allowed",
"query_columns": {
"comments": [
"CreationDate"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 608,
"evidence": "detailed content of ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many posts have a score of 10 on the list? | SELECT COUNT(id) FROM posts WHERE Score = 10 | simple | {
"gold_sql": "SELECT COUNT(id) FROM posts WHERE Score = 10",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Score"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 609,
"evidence": "score of 10 refers to Score = 10; post refer... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What are the name of badge that users who have the highest reputation obtained? | SELECT DISTINCT T2.name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Reputation = (SELECT MAX(Reputation) FROM users); | simple | {
"gold_sql": "SELECT DISTINCT T2.name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Reputation = (SELECT MAX(Reputation) FROM users);",
"permission": "allowed",
"query_columns": {
"badges": [
"UserId",
"name"
],
"users": [
"Id",
"Reputation"
]
},... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Mention the reputation of users who had obtained the badge on 7/19/2010 7:39:08 PM. | SELECT T1.Reputation FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Date = '2010-07-19 19:39:08.0' | simple | {
"gold_sql": "SELECT T1.Reputation FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Date = '2010-07-19 19:39:08.0'",
"permission": "allowed",
"query_columns": {
"badges": [
"Date",
"UserId"
],
"users": [
"Id",
"Reputation"
]
},
"missing_columns": ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the name of badge that the user whose display name is "Pierre" obtained? | SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'Pierre' | simple | {
"gold_sql": "SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'Pierre'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
"reason... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List out the dates that users who are located in Rochester, NY obtained their badges? | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT T2.Date FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Location = 'Rochester, NY'",
"permission": "denied",
"query_columns": {
"badges": [
"Date",
"UserId"
],
"users": [
"Id",
"Location"
]
},
"missing_columns": {
"users"... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Among the users who obtained the "Teacher" badge, calculate their percentage of users | SELECT CAST(COUNT(T1.Id) AS REAL) * 100 / (SELECT COUNT(Id) FROM users) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Name = 'Teacher' | simple | {
"gold_sql": "SELECT CAST(COUNT(T1.Id) AS REAL) * 100 / (SELECT COUNT(Id) FROM users) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Name = 'Teacher'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"Name",
"UserId"
],
"users": [
"Id"
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Among the users who obtained the "Organizer" badges, calculate the percentage of users who are teenagers. | SELECT CAST(SUM(IIF(T2.Age BETWEEN 13 AND 18, 1, 0)) AS REAL) * 100 / COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T1.`Name` = 'Organizer' | moderate | {
"gold_sql": "SELECT CAST(SUM(IIF(T2.Age BETWEEN 13 AND 18, 1, 0)) AS REAL) * 100 / COUNT(T1.Id) FROM badges AS T1 INNER JOIN users AS T2 ON T1.UserId = T2.Id WHERE T1.`Name` = 'Organizer'",
"permission": "allowed",
"query_columns": {
"badges": [
"Id",
"Name",
"UserId"
],
"users": [... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the comment's rating score of the post which was created on 7/19/2010 7:19:56 PM | SELECT T1.Score FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T1.CreationDate = '2010-07-19 19:19:56.0' | simple | {
"gold_sql": "SELECT T1.Score FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T1.CreationDate = '2010-07-19 19:19:56.0'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id"
],
"comments": [
"CreationDate",
"PostId",
"Score"
]
},
"missing_... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the detailed content of the comment of the post which was created on 7/19/2010 7:37:33 PM? | SELECT T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T1.CreationDate = '2010-07-19 19:37:33.0' | simple | {
"gold_sql": "SELECT T1.Text FROM comments AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T1.CreationDate = '2010-07-19 19:37:33.0'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id"
],
"comments": [
"CreationDate",
"PostId",
"Text"
]
},
"missing_co... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List the ages of users located in Vienna, Austria who have obtained badges. | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT T1.Age FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Location = 'Vienna, Austria' AND T1.Age IS NOT NULL",
"permission": "denied",
"query_columns": {
"badges": [
"UserId"
],
"users": [
"Age",
"Id",
"Location"
]
},
"missing_... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many adults who obtained the badge Supporter? | SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Name = 'Supporter' AND T1.Age BETWEEN 19 AND 65 | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Name = 'Supporter' AND T1.Age BETWEEN 19 AND 65",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"Age",
"Id"
]
},
"missing_c... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | State the number of views of users who obtained the badge on 7/19/2010 7:39:08 PM. | SELECT T1.Views FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Date = '2010-07-19 19:39:08.0' | simple | {
"gold_sql": "SELECT T1.Views FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Date = '2010-07-19 19:39:08.0'",
"permission": "allowed",
"query_columns": {
"badges": [
"Date",
"UserId"
],
"users": [
"Id",
"Views"
]
},
"missing_columns": {},
"rea... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What are the name of badges that users who have the lowest reputation obtained? | SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Reputation = (SELECT MIN(Reputation) FROM users) | simple | {
"gold_sql": "SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Reputation = (SELECT MIN(Reputation) FROM users)",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"Id",
"Reputation"
]
},
"missin... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | State the name of badge that the user whose display name is "Sharpie" obtained. | SELECT DISTINCT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'Sharpie' | simple | {
"gold_sql": "SELECT DISTINCT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.DisplayName = 'Sharpie'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many elders obtained the "Supporter" badge? | SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Age > 65 AND T2.Name = 'Supporter' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Age > 65 AND T2.Name = 'Supporter'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"Age",
"Id"
]
},
"missing_columns": {},
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the name of user with the ID of 30? | SELECT DisplayName FROM users WHERE Id = 30 | simple | {
"gold_sql": "SELECT DisplayName FROM users WHERE Id = 30",
"permission": "allowed",
"query_columns": {
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 624,
"evidence": "name of user refers to DisplayName;"
} |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users were from New York? | SELECT COUNT(Id) FROM users WHERE Location = 'New York' | simple | {
"gold_sql": "SELECT COUNT(Id) FROM users WHERE Location = 'New York'",
"permission": "allowed",
"query_columns": {
"users": [
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 625,
"evidence": "New York refers to Location;"
} |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many votes were made in 2010? | SELECT COUNT(id) FROM votes WHERE STRFTIME('%Y', CreationDate) = '2010' | simple | {
"gold_sql": "SELECT COUNT(id) FROM votes WHERE STRFTIME('%Y', CreationDate) = '2010'",
"permission": "allowed",
"query_columns": {
"votes": [
"CreationDate",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 626,
"evidence": ""
} |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users were adult? | SELECT COUNT(id) FROM users WHERE Age BETWEEN 19 AND 65 | simple | {
"gold_sql": "SELECT COUNT(id) FROM users WHERE Age BETWEEN 19 AND 65",
"permission": "allowed",
"query_columns": {
"users": [
"Age",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 627,
"evidence": "adult refers to user where Age BETW... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which users have the highest number of views? | SELECT Id, DisplayName FROM users WHERE Views = ( SELECT MAX(Views) FROM users ) | simple | {
"gold_sql": "SELECT Id, DisplayName FROM users WHERE Views = ( SELECT MAX(Views) FROM users )",
"permission": "allowed",
"query_columns": {
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 628,
"evidence": "Us... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Calculate the ratio of votes in 2010 and 2011. | SELECT CAST(SUM(IIF(STRFTIME('%Y', CreationDate) = '2010', 1, 0)) AS REAL) / NULLIF(SUM(IIF(STRFTIME('%Y', CreationDate) = '2011', 1, 0)), 0) FROM votes | simple | {
"gold_sql": "SELECT CAST(SUM(IIF(STRFTIME('%Y', CreationDate) = '2010', 1, 0)) AS REAL) / NULLIF(SUM(IIF(STRFTIME('%Y', CreationDate) = '2011', 1, 0)), 0) FROM votes",
"permission": "allowed",
"query_columns": {
"votes": [
"CreationDate"
]
},
"missing_columns": {},
"reason": "All required co... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What is the name of tags used by John Salvatier's? | SELECT T3.Tags FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T1.DisplayName = 'John Salvatier' | simple | {
"gold_sql": "SELECT T3.Tags FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T1.DisplayName = 'John Salvatier'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Tags"
],
"posthistory": [
"PostId",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many posts were created by Daniel Vassallo? | SELECT COUNT(T2.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName = 'Daniel Vassallo' | simple | {
"gold_sql": "SELECT COUNT(T2.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName = 'Daniel Vassallo'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_col... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many votes were made by Harlan? | SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN votes AS T3 ON T3.PostId = T2.PostId WHERE T1.DisplayName = 'Harlan' | simple | {
"gold_sql": "SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN votes AS T3 ON T3.PostId = T2.PostId WHERE T1.DisplayName = 'Harlan'",
"permission": "allowed",
"query_columns": {
"posthistory": [
"PostId",
"UserId"
],
"users": [
"Displ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Which post by slashnick has the most answers count? State the post ID. | SELECT T3.Id
FROM users AS T1
INNER JOIN posts AS T3 ON T1.Id = T3.OwnerUserId
WHERE T1.DisplayName = 'slashnick'
ORDER BY T3.AnswerCount DESC
LIMIT 1 | moderate | {
"gold_sql": "SELECT T3.Id \nFROM users AS T1 \nINNER JOIN posts AS T3 ON T1.Id = T3.OwnerUserId \nWHERE T1.DisplayName = 'slashnick' \nORDER BY T3.AnswerCount DESC \nLIMIT 1",
"permission": "allowed",
"query_columns": {
"posts": [
"AnswerCount",
"Id",
"OwnerUserId"
],
"users": [
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Among posts by Harvey Motulsky and Noah Snyder, which one has higher popularity? | SELECT T1.DisplayName FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T1.DisplayName = 'Harvey Motulsky' OR T1.DisplayName = 'Noah Snyder' GROUP BY T1.DisplayName ORDER BY SUM(T3.ViewCount) DESC LIMIT 1 | challenging | {
"gold_sql": "SELECT T1.DisplayName FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id WHERE T1.DisplayName = 'Harvey Motulsky' OR T1.DisplayName = 'Noah Snyder' GROUP BY T1.DisplayName ORDER BY SUM(T3.ViewCount) DESC LIMIT 1",
"permission": "allowed",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many posts by Matt Parker have more than 4 votes? | SELECT COUNT(*) FROM ( SELECT T2.Id FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId INNER JOIN votes AS T3 ON T3.PostId = T2.Id WHERE T1.DisplayName = 'Matt Parker' GROUP BY T2.Id HAVING COUNT(T3.Id) > 4); | moderate | {
"gold_sql": "SELECT COUNT(*) FROM ( SELECT T2.Id FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId INNER JOIN votes AS T3 ON T3.PostId = T2.Id WHERE T1.DisplayName = 'Matt Parker' GROUP BY T2.Id HAVING COUNT(T3.Id) > 4);",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many negative comments did Neil McGuigan get in his posts? | SELECT COUNT(T3.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId INNER JOIN comments AS T3 ON T2.Id = T3.PostId WHERE T1.DisplayName = 'Neil McGuigan' AND T3.Score < 60 | simple | {
"gold_sql": "SELECT COUNT(T3.Id) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId INNER JOIN comments AS T3 ON T2.Id = T3.PostId WHERE T1.DisplayName = 'Neil McGuigan' AND T3.Score < 60",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId"
],
"user... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | State all the tags used by Mark Meckes in his posts that doesn't have comments. | SELECT DISTINCT T3.Tags FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T3.Id = T2.PostId WHERE T1.DisplayName = 'Mark Meckes' AND T3.CommentCount = 0 AND T3.Tags IS NOT NULL | moderate | {
"gold_sql": "SELECT DISTINCT T3.Tags FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T3.Id = T2.PostId WHERE T1.DisplayName = 'Mark Meckes' AND T3.CommentCount = 0 AND T3.Tags IS NOT NULL",
"permission": "allowed",
"query_columns": {
"posts": [
"CommentCoun... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | List all the name of users that obtained the Organizer Badges. | SELECT T1.DisplayName FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.`Name` = 'Organizer' | simple | {
"gold_sql": "SELECT T1.DisplayName FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.`Name` = 'Organizer'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"DisplayName",
"Id"
]
},
"missing_columns": {},
"r... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Based on posts posted by Community, calculate the percentage of posts that use the R language. | SELECT CAST(SUM(CASE WHEN T1.Tags LIKE '%<r>%' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.Id) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T2.DisplayName = 'Community' | challenging | {
"gold_sql": "SELECT CAST(SUM(CASE WHEN T1.Tags LIKE '%<r>%' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.Id) FROM posts AS T1 INNER JOIN users AS T2 ON T1.OwnerUserId = T2.Id WHERE T2.DisplayName = 'Community'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"OwnerUserId",
"T... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Calculate the difference in view count of posts posted by Mornington and view count of posts posted by Amos. | SELECT SUM(CASE WHEN T1.DisplayName = 'Mornington' THEN T2.ViewCount ELSE 0 END) - SUM(CASE WHEN T1.DisplayName = 'Amos' THEN T2.ViewCount ELSE 0 END) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName IN ('Mornington', 'Amos') | moderate | {
"gold_sql": "SELECT SUM(CASE WHEN T1.DisplayName = 'Mornington' THEN T2.ViewCount ELSE 0 END) - SUM(CASE WHEN T1.DisplayName = 'Amos' THEN T2.ViewCount ELSE 0 END) FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T1.DisplayName IN ('Mornington', 'Amos')",
"permission": "allowed",
"query_c... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many users received commentator badges in 2014? | SELECT COUNT(DISTINCT UserId) FROM badges WHERE Name = 'Commentator' AND STRFTIME('%Y', Date) = '2014' | simple | {
"gold_sql": "SELECT COUNT(DISTINCT UserId) FROM badges WHERE Name = 'Commentator' AND STRFTIME('%Y', Date) = '2014'",
"permission": "allowed",
"query_columns": {
"badges": [
"Name",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 64... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many posts were created on 21st July, 2010? | SELECT COUNT(id) FROM postHistory WHERE date(CreationDate) = '2010-07-21' | simple | {
"gold_sql": "SELECT COUNT(id) FROM postHistory WHERE date(CreationDate) = '2010-07-21'",
"permission": "allowed",
"query_columns": {
"posthistory": [
"CreationDate",
"Id"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 642,
"evidence": "cr... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | What are the display names and ages of user who got the highest in views? | SELECT DisplayName, Age FROM users WHERE Views = ( SELECT MAX(Views) FROM users ) | simple | {
"gold_sql": "SELECT DisplayName, Age FROM users WHERE Views = ( SELECT MAX(Views) FROM users )",
"permission": "allowed",
"query_columns": {
"users": [
"Age",
"DisplayName"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 643,
"evidence": "... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Provide the last edit date and last edit user ID for the post "Detecting a given face in a database of facial images". | SELECT LastEditDate, LastEditorUserId FROM posts WHERE Title = 'Detecting a given face in a database of facial images' | simple | {
"gold_sql": "SELECT LastEditDate, LastEditorUserId FROM posts WHERE Title = 'Detecting a given face in a database of facial images'",
"permission": "allowed",
"query_columns": {
"posts": [
"LastEditDate",
"LastEditorUserId",
"Title"
]
},
"missing_columns": {},
"reason": "All requ... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | How many negative comments were given by user ID 13? | SELECT COUNT(Id) FROM comments WHERE UserId = 13 AND Score < 60 | simple | {
"gold_sql": "SELECT COUNT(Id) FROM comments WHERE UserId = 13 AND Score < 60",
"permission": "allowed",
"query_columns": {
"comments": [
"Id",
"Score",
"UserId"
]
},
"missing_columns": {},
"reason": "All required columns are permitted",
"question_id": 645,
"evidence": "negati... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Describe the post title which got positive comments and display names of the users who posted those comments. | SELECT DISTINCT T1.Title, T2.UserDisplayName
FROM posts AS T1
INNER JOIN comments AS T2 ON T1.Id = T2.PostId
WHERE T2.Score > 60 AND T1.Title IS NOT NULL AND T2.UserDisplayName IS NOT NULL; | simple | {
"gold_sql": "SELECT DISTINCT T1.Title, T2.UserDisplayName\nFROM posts AS T1\nINNER JOIN comments AS T2 ON T1.Id = T2.PostId\nWHERE T2.Score > 60 AND T1.Title IS NOT NULL AND T2.UserDisplayName IS NOT NULL;",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"Title"
],
"comment... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Provide the badge names received in 2011 for the user whose location is in the North Pole. | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT T2.Name FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE STRFTIME('%Y', T2.Date) = '2011' AND T1.Location = 'North Pole'",
"permission": "denied",
"query_columns": {
"badges": [
"Date",
"Name",
"UserId"
],
"users": [
"Id",
"Locatio... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Provide the users' display names and available website URLs of the post with favorite count of more than 150. | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT T1.DisplayName, T1.WebsiteUrl FROM users AS T1 INNER JOIN posts AS T2 ON T1.Id = T2.OwnerUserId WHERE T2.FavoriteCount > 150",
"permission": "denied",
"query_columns": {
"posts": [
"FavoriteCount",
"OwnerUserId"
],
"users": [
"DisplayName",
"Id",
"We... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Describe the post history counts and last edit date of the post title "What is the best introductory Bayesian statistics textbook?" | SELECT COUNT(T1.Id), T2.LastEditDate FROM postHistory AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T2.Title = 'What is the best introductory Bayesian statistics textbook?' | simple | {
"gold_sql": "SELECT COUNT(T1.Id), T2.LastEditDate FROM postHistory AS T1 INNER JOIN posts AS T2 ON T1.PostId = T2.Id WHERE T2.Title = 'What is the best introductory Bayesian statistics textbook?'",
"permission": "allowed",
"query_columns": {
"posts": [
"Id",
"LastEditDate",
"Title"
],
... |
codebase_community | ##Instruction:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Database: codebase_community
Total Tables: 8
Total Columns: 71
Table Schemas:
Table: badges (4 columns)
-------------------------
• Id (integer): the badge id
• UserId (integer): the unique id of the user
• Name (text): the... | CommunityModerator | {
"badges": [
"Id",
"UserId",
"Name",
"Date"
],
"comments": [
"*"
],
"postHistory": [
"*"
],
"postLinks": [
"*"
],
"posts": [
"Id",
"PostTypeId",
"AcceptedAnswerId",
"CreaionDate",
"Score",
"ViewCount",
"Body",
"OwnerUserId",
"LasActivity... | Describe the last accessed date and location of the users who received the outliers badge. | Sorry, I cannot answer. | simple | {
"gold_sql": "SELECT T1.LastAccessDate, T1.Location FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T2.Name = 'outliers'",
"permission": "denied",
"query_columns": {
"badges": [
"Name",
"UserId"
],
"users": [
"Id",
"LastAccessDate",
"Location"
]
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.