human
Schema:
venue (venueId, venueName)
author (authorId, authorName)
dataset (datasetId, datasetName)
journal (journalId, journalName)
keyphrase (keyphraseId, keyphraseName)
paper (paperId, title, venueId, year, numCiting, numCitedBy, journalId)
cite (citingPaperId, citedPaperId)
paperDataset (paperId, datasetId)
paperKeyphrase (paperId, keyphraseId)
writes (paperId, authorId)
Please answer with SQL.
assistant
Sure, I understand.
human
How many papers did michael i. jordan publish in 2016 ?
assistant
SELECT DISTINCT COUNT ( t2.paperid ) FROM writes AS t2 JOIN author AS t1 ON t2.authorid = t1.authorid JOIN paper AS t3 ON t2.paperid = t3.paperid WHERE t1.authorname = 'michael i. jordan' AND t3.year = 2016;
human
papers from 2014
assistant
SELECT DISTINCT paperid FROM paper WHERE YEAR = 2014;
human
the papers at eccv in 2014 using ImageNet dataset
assistant
SELECT DISTINCT t3.paperid FROM paperdataset AS t2 JOIN dataset AS t1 ON t2.datasetid = t1.datasetid JOIN paper AS t3 ON t3.paperid = t2.paperid JOIN venue AS t4 ON t4.venueid = t3.venueid WHERE t1.datasetname = 'ImageNet' AND t3.year = 2014 AND t4.venuename = 'eccv';
human
papers published in the last year
assistant
SELECT DISTINCT paperid FROM paper WHERE YEAR = ( SELECT MAX ( YEAR ) FROM paper );
human
What conference does Daniella Coelho publish in ?
assistant
SELECT DISTINCT t3.venueid FROM writes AS t2 JOIN author AS t1 ON t2.authorid = t1.authorid JOIN paper AS t3 ON t2.paperid = t3.paperid WHERE t1.authorname = 'Daniella Coelho';
human
Does ali farhadi have a paper in eccv in 2016 ?
assistant
SELECT DISTINCT t3.paperid FROM venue AS t4 JOIN paper AS t3 ON t4.venueid = t3.venueid JOIN writes AS t2 ON t2.paperid = t3.paperid JOIN author AS t1 ON t2.authorid = t1.authorid WHERE t1.authorname = "ali farhadi" AND t3.year = 2016 AND t4.venuename = "eccv" ;