Did M1 write a film , edit a film 's sequel and prequel , and produce M2
SELECT count(*) WHERE {
?x0 ns:film.film.prequel ?x1 .
?x0 ns:film.film.sequel ?x1 .
?x1 a ns:film.film .
?x2 a ns:film.film .
M1 ns:film.editor.film ?x0 .
M1 ns:film.producer.film|ns:film.production_company.films M2 .
M1 ns:film.writer.film ?x2
}