Question: Which work was awarded when David Foster (the one that received Grammy Award for Best Musical Theater Album) was nominated for Grammy Award for Song of the Year?
Choices: The Sunshine Boys
Say
The Player
None So Blind
Phil Spector
The Garry Moore Show
Maytime
King
The Knight
After the Love Has Gone
SPARQL: SELECT DISTINCT ?qpv WHERE { ?e_1 <pred:name> "David Foster" . ?e_1 <award_received> ?e_3 . ?e_3 <pred:name> "Grammy Award for Best Musical Theater Album" . ?e_2 <pred:name> "Grammy Award for Song of the Year" . ?e_1 <nominated_for> ?e_2 . [ <pred:fact_h> ?e_1 ; <pred:fact_r> <nominated_for> ; <pred:fact_t> ?e_2 ] <for_work> ?qpv .  }
Program:
function: Find
inputs: Grammy Award for Best Musical Theater Album
function: Relate
dependencies: 0
inputs: award received
backward
function: Find
inputs: David Foster
function: And
dependencies: 1
2
function: Find
inputs: Grammy Award for Song of the Year
function: QueryRelationQualifier
dependencies: 3
4
inputs: nominated for
for work
Answer: After the Love Has Gone