When was Charles VI, Holy Roman Emperor, the King of Hungary?
SELECT ?value WHERE { wd:/Charles VI, Holy Roman Emperor/ p:/position held/ ?s . ?s ps:/position held/ wd:/Apostolic King of Hungary/ . ?s pq:/start time/ ?value}