db_id stringlengths 4 31 | SQL stringlengths 18 1.45k | input_sequence stringlengths 148 11k | question stringlengths 16 325 |
|---|---|---|---|
codebase_community | select t1.displayname from users as t1 inner join badges as t2 on t1.id = t2.userid where t2.`name` = 'organizer' | Question: list all the name of users that obtained the organizer badges. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> ... | list all the name of users that obtained the organizer badges. |
codebase_community | select cast(sum(iif(t3.tagname = 'r', 1, 0)) as real) * 100 / count(t1.id) from users as t1 inner join posthistory as t2 on t1.id = t2.userid inner join tags as t3 on t3.excerptpostid = t2.postid where t1.displayname = 'community' | Question: based on posts posted by community, calculate the percentage of posts that use the r language. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment... | based on posts posted by community, calculate the percentage of posts that use the r language. |
codebase_community | select sum(iif(t1.displayname = 'mornington', t3.viewcount, 0)) - sum(iif(t1.displayname = 'amos', t3.viewcount, 0)) as diff from users as t1 inner join posthistory as t2 on t1.id = t2.userid inner join posts as t3 on t3.id = t2.postid | Question: calculate the difference in view count from post posted by mornington and view count from posts posted by amos. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, User... | calculate the difference in view count from post posted by mornington and view count from posts posted by amos. |
codebase_community | select count(id) from badges where name = 'commentator' and strftime('%y', date) = '2014' | Question: how many users received commentator badges in 2014? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Creatio... | how many users received commentator badges in 2014? |
codebase_community | select count(id) from posthistory where date(creationdate) = '2010-07-21' | Question: how many posts were created on 21st july, 2010? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDat... | how many posts were created on 21st july, 2010? |
codebase_community | select displayname, age from users where views = ( select max(views) from users ) | Question: what are the display names and ages of user who got the highest in views? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. po... | what are the display names and ages of user who got the highest in views? |
codebase_community | select lasteditdate, lasteditoruserid from posts where title = 'detecting a given face in a database of facial images' | Question: provide the last edit date and last edit user id for the post 'detecting a given face in a database of facial images'. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDat... | provide the last edit date and last edit user id for the post 'detecting a given face in a database of facial images'. |
codebase_community | select count(id) from comments where userid = 13 and score < 60 | Question: how many negative comments were given by user id 13? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Creati... | how many negative comments were given by user id 13? |
codebase_community | select t1.title, t2.userdisplayname from posts as t1 inner join comments as t2 on t2.postid = t2.id where t1.score > 60 | Question: describe the post title which got positive comments and display names of the users who posted those comments. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId... | describe the post title which got positive comments and display names of the users who posted those comments. |
codebase_community | 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' | Question: provide the badge names received in 2011 for the user whose location is in the north pole. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, Us... | provide the badge names received in 2011 for the user whose location is in the north pole. |
codebase_community | select t1.displayname, t1.websiteurl from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where t2.favoritecount > 150 | Question: provide the users' display names and available website urls of the post with favorite count of more than 150. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId... | provide the users' display names and available website urls of the post with favorite count of more than 150. |
codebase_community | select 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?' | Question: describe the post history counts and last edit date of the post title 'what is the best introductory bayesian statistics textbook?' | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID... | describe the post history counts and last edit date of the post title 'what is the best introductory bayesian statistics textbook?' |
codebase_community | select t1.lastaccessdate, t1.location from users as t1 inner join badges as t2 on t1.id = t2.userid where t2.name = 'outliers' | Question: describe the last accessed date and location of the users who received the outliers badge. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, Us... | describe the last accessed date and location of the users who received the outliers badge. |
codebase_community | select t3.title from postlinks as t1 inner join posts as t2 on t1.postid = t2.id inner join posts as t3 on t1.relatedpostid = t3.id where t2.title = 'how to tell if something happened in a data set which monitors a value over time' | Question: provide the related post title of 'how to tell if something happened in a data set which monitors a value over time'. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate... | provide the related post title of 'how to tell if something happened in a data set which monitors a value over time'. |
codebase_community | select t1.postid, t2.name from posthistory as t1 inner join badges as t2 on t1.userid = t2.userid where t1.userdisplayname = 'samuel' and strftime('%y', t1.creationdate) = '2013' and strftime('%y', t2.date) = '2013' | Question: list the post ids and badge names of the user samuel in 2013. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> I... | list the post ids and badge names of the user samuel in 2013. |
codebase_community | select displayname from users where id = ( select owneruserid from posts order by viewcount desc limit 1 ) | Question: what is the owner's display name of the most popular post? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, ... | what is the owner's display name of the most popular post? |
codebase_community | select t3.displayname, t3.location from tags as t1 inner join posts as t2 on t1.excerptpostid = t2.id inner join users as t3 on t3.id = t2.owneruserid where t1.tagname = 'hypothesis-testing' | Question: mention the display name and location of the user who owned the excerpt post with hypothesis-testing tag. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Te... | mention the display name and location of the user who owned the excerpt post with hypothesis-testing tag. |
codebase_community | select t3.title, t2.linktypeid from posts as t1 inner join postlinks as t2 on t1.id = t2.postid inner join posts as t3 on t2.relatedpostid = t3.id where t1.title = 'what are principal component scores?' | Question: write down the related posts titles and link type ids of the post 'what are principal component scores?'. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Te... | write down the related posts titles and link type ids of the post 'what are principal component scores?'. |
codebase_community | select displayname from users where id = ( select owneruserid from posts where parentid is not null order by score desc limit 1 ) | Question: describe the display name of the parent id for child post with the highest score. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplay... | describe the display name of the parent id for child post with the highest score. |
codebase_community | select displayname, websiteurl from users where id = ( select userid from votes where votetypeid = 8 order by bountyamount desc limit 1 ) | Question: under the vote type of 8, provide the display names and websites urls of the user who got the highest bounty amount. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate,... | under the vote type of 8, provide the display names and websites urls of the user who got the highest bounty amount. |
codebase_community | select title from posts order by viewcount desc limit 5 | Question: what are the titles of the top 5 posts with the highest popularity? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLink... | what are the titles of the top 5 posts with the highest popularity? |
codebase_community | select count(id) from tags where count between 5000 and 7000 | Question: how many tags have post count between 5,000 to 7,000? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Creat... | how many tags have post count between 5,000 to 7,000? |
codebase_community | select owneruserid from posts where favoritecount = ( select max(favoritecount) from posts ) | Question: what is the owner user id of the most valuable post? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Creati... | what is the owner user id of the most valuable post? |
codebase_community | select age from users where reputation = ( select max(reputation) from users ) | Question: how old is the most influential user? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate, PostId,... | how old is the most influential user? |
codebase_community | select count(t1.id) from posts as t1 inner join votes as t2 on t1.id = t2.postid where t2.bountyamount = 50 and strftime('%y', t2.creationdate) = '2011' | Question: how many posts with votes that were created in 2011 have a bounty of 50? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. pos... | how many posts with votes that were created in 2011 have a bounty of 50? |
codebase_community | select id from users where age = ( select min(age) from users ) | Question: what is the id of the youngest user? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate, PostId, ... | what is the id of the youngest user? |
codebase_community | select score from posts where id = ( select excerptpostid from tags order by count desc limit 1 ) | Question: what is the score of the post with the most popular tag? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Cr... | what is the score of the post with the most popular tag? |
codebase_community | select cast(count(t1.id) as real) / 12 from postlinks as t1 inner join posts as t2 on t1.postid = t2.id where t2.answercount <= 2 and strftime('%y', t1.creationdate) = '2010' | Question: what is the average monthly number of links created in 2010 for posts that have no more than 2 answers? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text... | what is the average monthly number of links created in 2010 for posts that have no more than 2 answers? |
codebase_community | select t2.id from votes as t1 inner join posts as t2 on t1.postid = t2.id where t1.userid = 1465 order by t2.favoritecount desc limit 1 | Question: among the posts that were voted by user 1465, what is the id of the most valuable post? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserD... | among the posts that were voted by user 1465, what is the id of the most valuable post? |
codebase_community | select t1.title from posts as t1 inner join postlinks as t2 on t2.postid = t1.id order by t1.creaiondate limit 1 | Question: what is the title of the post with the oldest post link? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Cr... | what is the title of the post with the oldest post link? |
codebase_community | select t1.displayname from users as t1 inner join badges as t2 on t1.id = t2.userid group by t1.displayname order by count(t1.id) desc limit 1 | Question: what is the display name of the user who acquired the highest amount of badges? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayNa... | what is the display name of the user who acquired the highest amount of badges? |
codebase_community | select t2.creationdate from users as t1 inner join votes as t2 on t1.id = t2.userid where t1.displayname = 'chl' order by t2.creationdate limit 1 | Question: when did 'chl' cast its first vote in a post? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate,... | when did 'chl' cast its first vote in a post? |
codebase_community | select t2.creaiondate from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where t1.age is not null order by t1.age, t2.creaiondate limit 1 | Question: what is the date when the youngest user made his or her first post? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLink... | what is the date when the youngest user made his or her first post? |
codebase_community | select t1.displayname from users as t1 inner join badges as t2 on t1.id = t2.userid where t2.`name` = 'autobiographer' order by t2.date limit 1 | Question: what is the display name of the user who acquired the first autobiographer badge? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplay... | what is the display name of the user who acquired the first autobiographer badge? |
codebase_community | select count(t1.id) from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where t1.location = 'united kingdom' and t2.favoritecount >= 4 | Question: among the users located in united kingdom, how many users whose post have a total favorite amount of 4 or more? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, User... | among the users located in united kingdom, how many users whose post have a total favorite amount of 4 or more? |
codebase_community | select avg(postid) from votes where userid in ( select id from users where age = ( select max(age) from users ) ) | Question: what is the average number of posts voted by the oldest users? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> ... | what is the average number of posts voted by the oldest users? |
codebase_community | select displayname from users where reputation = ( select max(reputation) from users ) | Question: who has the highest reputation? please give the display name. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> I... | who has the highest reputation? please give the display name. |
codebase_community | select count(id) from users where reputation > 2000 and views > 1000 | Question: how many users whose reputations are higher than 2000 and the number of views is higher than 1000? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Com... | how many users whose reputations are higher than 2000 and the number of views is higher than 1000? |
codebase_community | select displayname from users where age between 19 and 65 | Question: please list all display names of users who are adults. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Crea... | please list all display names of users who are adults. |
codebase_community | select count(t1.id) from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where strftime('%y', t2.creaiondate) = '2010' and t1.displayname = 'jay stevens' | Question: how many posts did jay stevens have in 2010? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate, ... | how many posts did jay stevens have in 2010? |
codebase_community | select t2.id, t2.title from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where t1.displayname = 'harvey motulsky' order by t2.viewcount desc limit 1 | Question: which post by harvey motulsky has the most views? please give the id and title of this post. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, ... | which post by harvey motulsky has the most views? please give the id and title of this post. |
codebase_community | select t1.id, t2.title from users as t1 inner join posts as t2 on t1.id = t2.owneruserid order by t2.score desc limit 1 | Question: which post has the highest score? please give its id and title's name. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postL... | which post has the highest score? please give its id and title's name. |
codebase_community | select avg(t2.score) from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where t1.displayname = 'stephen turner' | Question: what is the average score of stephen turner's posts? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Creati... | what is the average score of stephen turner's posts? |
codebase_community | select t1.displayname from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where strftime('%y', t2.creaiondate) = '2011' and t2.viewcount > 20000 | Question: please list the users' display names whose posts had over 20000 views in 2011. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayNam... | please list the users' display names whose posts had over 20000 views in 2011. |
codebase_community | select t2.owneruserid, t1.displayname from users as t1 inner join posts as t2 on t1.id = t2.owneruserid where strftime('%y', t1.creationdate) = '2010' order by t2.favoritecount desc limit 1 | Question: which is the most valuable post in 2010? please give its id and the owner's display name. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, Use... | which is the most valuable post in 2010? please give its id and the owner's display name. |
codebase_community | select cast(sum(iif(strftime('%y', t2.creaiondate) = '2011' and t1.reputation > 1000, 1, 0)) as real) * 100 / count(t1.id) from users as t1 inner join posts as t2 on t1.id = t2.owneruserid | Question: what is the percentage of posts whose owners had a reputation of over 1000 in 2011? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDispl... | what is the percentage of posts whose owners had a reputation of over 1000 in 2011? |
codebase_community | select cast(sum(iif(age between 13 and 18, 1, 0)) as real) * 100 / count(id) from users | Question: identify the percentage of teenage users. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate, Pos... | identify the percentage of teenage users. |
codebase_community | select t2.viewcount, t3.displayname from posthistory as t1 inner join posts as t2 on t1.postid = t2.id inner join users as t3 on t2.lasteditoruserid = t3.id where t1.text = 'computer game datasets' | Question: identify the total views on the post 'computer game datasets'. name the user who posted it last time. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, ... | identify the total views on the post 'computer game datasets'. name the user who posted it last time. |
codebase_community | select id from posts where viewcount > ( select avg(viewcount) from posts ) | Question: identify the total number of posts with views above average. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id... | identify the total number of posts with views above average. |
codebase_community | select count(t2.id) from posts as t1 inner join comments as t2 on t1.id = t2.postid group by t1.id order by sum(t1.score) desc limit 1 | Question: how many comments were added to the post with the highest score? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -... | how many comments were added to the post with the highest score? |
codebase_community | select count(id) from posts where viewcount > 35000 and commentcount = 0 | Question: identify the number of posts that have been viewed over 35000 times but have received no comments from other users. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, ... | identify the number of posts that have been viewed over 35000 times but have received no comments from other users. |
codebase_community | select t2.displayname, t2.location from posts as t1 inner join users as t2 on t1.owneruserid = t2.id where t2.id = 183 order by t1.lasteditdate desc limit 1 | Question: identify the display name and location of the user, who was the last to edit the post with id 183. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Com... | identify the display name and location of the user, who was the last to edit the post with id 183. |
codebase_community | select t1.name from badges as t1 inner join users as t2 on t1.userid = t2.id where t2.displayname = 'emmett' order by t1.date desc limit 1 | Question: identify the latest badge awarded to the user with the display name emmett. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. ... | identify the latest badge awarded to the user with the display name emmett. |
codebase_community | select count(id) from users where age between 19 and 65 and upvotes > 5000 | Question: identify the number of adult users who have cast over 5000 upvotes. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLink... | identify the number of adult users who have cast over 5000 upvotes. |
codebase_community | select t1.date - t2.creationdate from badges as t1 inner join users as t2 on t1.userid = t2.id where t2.displayname = 'zolomon' | Question: how long did it take the user, known by his or her display name 'zolomon' to get the badge? count from the date the user's account was created. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, ... | how long did it take the user, known by his or her display name 'zolomon' to get the badge? count from the date the user's account was created. |
codebase_community | select count(t2.id) from users as t1 inner join posts as t2 on t1.id = t2.owneruserid inner join comments as t3 on t3.postid = t2.id order by t1.creationdate desc limit 1 | Question: identify the number of posts and comments left by the user, who has the latest created user account. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, C... | identify the number of posts and comments left by the user, who has the latest created user account. |
codebase_community | select t3.text, t1.displayname 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 t2.title = 'analysing wind data with r' order by t1.creationdate desc limit 1 | Question: provide the text of the latest comment to the post with the title 'analysing wind data with r' and the display name of the user who left it. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, Rev... | provide the text of the latest comment to the post with the title 'analysing wind data with r' and the display name of the user who left it. |
codebase_community | select count(id) from badges where `name` = 'citizen patrol' | Question: how many users were awarded with 'citizen patrol' badge? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, Cr... | how many users were awarded with 'citizen patrol' badge? |
codebase_community | select count(id) from tags where tagname = 'careers' | Question: count the number of posts with a tag specified as 'careers'. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id... | count the number of posts with a tag specified as 'careers'. |
codebase_community | select reputation, views from users where displayname = 'jarrod dixon' | Question: what is the reputation and view count of the user, who is known by his or her display name 'jarrod dixon'? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, T... | what is the reputation and view count of the user, who is known by his or her display name 'jarrod dixon'? |
codebase_community | select commentcount, answercount from posts where title = 'clustering 1d data' | Question: how many comments and answers were left by the users on the post with the title 'clustering 1d data'? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, ... | how many comments and answers were left by the users on the post with the title 'clustering 1d data'? |
codebase_community | select creationdate from users where displayname = 'irishstat' | Question: when did the user known as 'irishstat' create his or her account? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks ... | when did the user known as 'irishstat' create his or her account? |
codebase_community | select count(id) from votes where bountyamount >= 30 | Question: identify the number of posts that offer a bounty amount over 30. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -... | identify the number of posts that offer a bounty amount over 30. |
codebase_community | select cast(sum(case when t2.score >= 50 then 1 else 0 end) as real) * 100 / count(t1.id) from users t1 inner join posts t2 on t1.id = t2.owneruserid inner join ( select max(reputation) as max_reputation from users ) t3 on t1.reputation = t3.max_reputation | Question: among all the posts posted by the most influential user, identify the percentage with a score above 50. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text... | among all the posts posted by the most influential user, identify the percentage with a score above 50. |
codebase_community | select count(id) from posts where score < 20 | Question: how many posts have a score less than 20? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> Id, CreationDate, Pos... | how many posts have a score less than 20? |
codebase_community | select count(id) from tags where count <= 20 and id < 15 | Question: among the tags with tag id below 15, how many of them have 20 count of posts and below? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserD... | among the tags with tag id below 15, how many of them have 20 count of posts and below? |
codebase_community | select excerptpostid, wikipostid from tags where tagname = 'sample' | Question: what is the excerpt post id and wiki post id of the tag named sample? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLi... | what is the excerpt post id and wiki post id of the tag named sample? |
codebase_community | select t2.reputation, t2.upvotes from comments as t1 inner join users as t2 on t1.userid = t2.id where t1.text = 'fine, you win :)' | Question: give the user's reputation and up vote number of the user that commented 'fine, you win :)'. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, ... | give the user's reputation and up vote number of the user that commented 'fine, you win :)'. |
codebase_community | select t1.text from comments as t1 inner join posts as t2 on t1.postid = t2.id where t2.title like '%linear regression%' | Question: give the texts commented on the post about linear regression. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks -> I... | give the texts commented on the post about linear regression. |
codebase_community | select text from comments where postid in ( select id from posts where viewcount between 100 and 150 ) order by score desc limit 1 | Question: among the posts with views ranging from 100 to 150, what is the comment with the highest score? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Commen... | among the posts with views ranging from 100 to 150, what is the comment with the highest score? |
codebase_community | select t2.creationdate, t2.age from comments as t1 inner join users as t2 on t1.userid = t2.id where t1.text like '%http://%' | Question: list the creation date and age of the user that commented with webiste. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. post... | list the creation date and age of the user that commented with webiste. |
codebase_community | select count(t1.id) from comments as t1 inner join posts as t2 on t1.postid = t2.id where t2.viewcount < 5 and t2.score = 0 | Question: in comments with 0 score, how many of the posts have view count lower than 5? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName... | in comments with 0 score, how many of the posts have view count lower than 5? |
codebase_community | select count(t1.id) from comments as t1 inner join posts as t2 on t1.postid = t2.id where t2.commentcount = 1 and t2.score = 0 | Question: in posts with 1 comment, how many of the comments have 0 score? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. postLinks ->... | in posts with 1 comment, how many of the comments have 0 score? |
codebase_community | select count(t1.id) from comments as t1 inner join users as t2 on t1.userid = t2.id where t1.score = 0 and t2.age = 40 | Question: among products comments with 0 score, what is the total number of users ages 40 years old? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, Us... | among products comments with 0 score, what is the total number of users ages 40 years old? |
codebase_community | select t2.id, t1.text from comments as t1 inner join posts as t2 on t1.postid = t2.id where t2.title = 'group differences on a five point likert item' | Question: what is the post id and the comments commented in the post titled by 'group differences on a five point likert item'? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate... | what is the post id and the comments commented in the post titled by 'group differences on a five point likert item'? |
codebase_community | select t2.upvotes from comments as t1 inner join users as t2 on t1.userid = t2.id where t1.text = 'r is also lazy evaluated.' | Question: what is the up vote number of the user that commented 'r is also lazy evaluated.'? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDispla... | what is the up vote number of the user that commented 'r is also lazy evaluated.'? |
codebase_community | select t1.text from comments as t1 inner join users as t2 on t1.userid = t2.id where t2.displayname = 'harvey motulsky' | Question: list the comments commented by the user with a username of harvey motulsky. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Comment, UserDisplayName. ... | list the comments commented by the user with a username of harvey motulsky. |
codebase_community | select t2.displayname from comments as t1 inner join users as t2 on t1.userid = t2.id where t1.score between 1 and 5 and t2.downvotes = 0 | Question: in comments with score between 1 to 5, list down the display names of the users with 0 down votes. | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, Com... | in comments with score between 1 to 5, list down the display names of the users with 0 down votes. |
codebase_community | select cast(sum(iif(t1.upvotes = 0, 1, 0)) as real) / count(t1.id) as per from users as t1 inner join comments as t2 on t1.id = t2.userid where t2.score between 5 and 10 | Question: among the comments with scores between 5 to 10, what is the percentage of the users with 0 up votes? | Tables: badges -> Id, UserId, Name, Date. comments -> Id, PostId, Score, Text, CreationDate, UserId, UserDisplayName. postHistory -> Id, PostHistoryTypeId, PostId, RevisionGUID, CreationDate, UserId, Text, C... | among the comments with scores between 5 to 10, what is the percentage of the users with 0 up votes? |
superhero | select t3.power_name from superhero as t1 inner join hero_power as t2 on t1.id = t2.hero_id inner join superpower as t3 on t2.power_id = t3.id where t1.superhero_name = '3-d man' | Question: please list all the superpowers of 3-d man. | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id... | please list all the superpowers of 3-d man. |
superhero | select count(t1.hero_id) from hero_power as t1 inner join superpower as t2 on t1.power_id = t2.id where t2.power_name = 'super strength' | Question: how many superheroes have the super power of 'super strength'? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour... | how many superheroes have the super power of 'super strength'? |
superhero | select count(t1.id) from superhero as t1 inner join hero_power as t2 on t1.id = t2.hero_id inner join superpower as t3 on t2.power_id = t3.id where t3.power_name = 'super strength' and t1.height_cm > 200 | Question: among the superheroes with the super power of 'super strength', how many of them have a height of over 200cm? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, f... | among the superheroes with the super power of 'super strength', how many of them have a height of over 200cm? |
superhero | select distinct t1.full_name from superhero as t1 inner join hero_power as t2 on t1.id = t2.hero_id group by t1.full_name having count(t2.power_id) > 15 | Question: please list the full names of all the superheroes with over 15 super powers. | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_i... | please list the full names of all the superheroes with over 15 super powers. |
superhero | select count(t1.id) from superhero as t1 inner join colour as t2 on t1.eye_colour_id = t2.id where t2.colour = 'blue' | Question: how many superheroes have blue eyes? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id, race_... | how many superheroes have blue eyes? |
superhero | select t2.colour from superhero as t1 inner join colour as t2 on t1.skin_colour_id = t2.id where t1.superhero_name = 'apocalypse' | Question: what is the colour of apocalypse's skin? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id, r... | what is the colour of apocalypse's skin? |
superhero | select count(t1.id) from superhero as t1 inner join hero_power as t2 on t1.id = t2.hero_id inner join superpower as t3 on t2.power_id = t3.id inner join colour as t4 on t1.eye_colour_id = t4.id where t3.power_name = 'agility' and t4.colour = 'blue' | Question: among the superheroes with blue eyes, how many of them have the super power of 'agility'? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id,... | among the superheroes with blue eyes, how many of them have the super power of 'agility'? |
superhero | select t1.superhero_name from superhero as t1 inner join colour as t2 on t1.eye_colour_id = t2.id inner join colour as t3 on t1.hair_colour_id = t3.id where t2.colour = 'blue' and t3.colour = 'blond' | Question: please list the superhero names of all the superheroes that have blue eyes and blond hair. | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id... | please list the superhero names of all the superheroes that have blue eyes and blond hair. |
superhero | select count(t1.id) from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t2.publisher_name = 'marvel comics' | Question: how many superheroes are published by marvel comics? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_... | how many superheroes are published by marvel comics? |
superhero | select t1.full_name from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t2.publisher_name = 'marvel comics' order by t1.height_cm desc limit 1 | Question: please give the full name of the tallest hero published by marvel comics. | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, ... | please give the full name of the tallest hero published by marvel comics. |
superhero | select t2.publisher_name from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t1.superhero_name = 'sauron' | Question: who is the publisher of sauron? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id, race_id, p... | who is the publisher of sauron? |
superhero | select count(t1.id) from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id inner join colour as t3 on t1.eye_colour_id = t3.id where t2.publisher_name = 'marvel comics' and t3.colour = 'blue' | Question: among the superheroes from marvel comics, how many of them have blue eyes? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id,... | among the superheroes from marvel comics, how many of them have blue eyes? |
superhero | select avg(t1.height_cm) from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t2.publisher_name = 'marvel comics' | Question: what is the average height of the superheroes from marvel comics? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_col... | what is the average height of the superheroes from marvel comics? |
superhero | select cast(count(case when t3.power_name = 'super strength' then t1.id else null end) as real) * 100 / count(t1.id) from superhero as t1 inner join hero_power as t2 on t1.id = t2.hero_id inner join superpower as t3 on t2.power_id = t3.id inner join publisher as t4 on t1.publisher_id = t4.id where t4.publisher_name = '... | Question: among the superheroes from marvel comics, what is the percentage of those who have the super power of 'super strength'? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhe... | among the superheroes from marvel comics, what is the percentage of those who have the super power of 'super strength'? |
superhero | select count(t1.id) from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t2.publisher_name = 'dc comics' | Question: how many superheroes did dc comics publish? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id... | how many superheroes did dc comics publish? |
superhero | select t2.publisher_name from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id inner join hero_attribute as t3 on t1.id = t3.hero_id inner join attribute as t4 on t3.attribute_id = t4.id where t4.attribute_name = 'speed' order by t3.attribute_value limit 1 | Question: which publisher published the slowest superhero? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colo... | which publisher published the slowest superhero? |
superhero | select count(t1.id) from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id inner join colour as t3 on t1.eye_colour_id = t3.id where t2.publisher_name = 'marvel comics' and t3.colour = 'gold' | Question: how many gold-eyed superheroes did marvel comics publish? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, ... | how many gold-eyed superheroes did marvel comics publish? |
superhero | select t2.publisher_name from superhero as t1 inner join publisher as t2 on t1.publisher_id = t2.id where t1.superhero_name = 'blue beetle ii' | Question: what is the publisher's name of blue beetle ii? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colou... | what is the publisher's name of blue beetle ii? |
superhero | select count(t1.id) from superhero as t1 inner join colour as t2 on t1.hair_colour_id = t2.id where t2.colour = 'blond' | Question: how many superheroes with blonde hair are there? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colo... | how many superheroes with blonde hair are there? |
superhero | select t1.superhero_name from superhero as t1 inner join hero_attribute as t2 on t1.id = t2.hero_id inner join attribute as t3 on t2.attribute_id = t3.id where t3.attribute_name = 'intelligence' order by t2.attribute_value limit 1 | Question: who is the dumbest superhero? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id, race_id, pub... | who is the dumbest superhero? |
superhero | select t2.race from superhero as t1 inner join race as t2 on t1.race_id = t2.id where t1.superhero_name = 'copycat' | Question: what is copycat's race? | Tables: alignment -> id, alignment. attribute -> id, attribute_name. colour -> id, colour. gender -> id, gender. publisher -> id, publisher_name. race -> id, race. superhero -> id, superhero_name, full_name, gender_id, eye_colour_id, hair_colour_id, skin_colour_id, race_id, publisher... | what is copycat's race? |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.