What was written by M0 and produced by a film director that M2 was played by
SELECT DISTINCT ?x0 WHERE {
?x0 ns:film.film.produced_by|ns:film.film.production_companies ?x1 .
?x0 ns:film.film.written_by M0 .
?x1 a ns:film.director .
?x1 ns:film.actor.film/ns:film.performance.character M2
}