我不知道如何表达关于SQL Query(实际上是HiveQL Query)的关系代数,如下所示:
SELECT a0.subject FROM ( SELECT subject FROM table_name WHERE predicate='headOf'
and object='Department8' ) a0 JOIN ( SELECT subject FROM table_name WHERE
predicate='teacherOf' and object='GraduateCourse6' ) a1 on a0.subject = a1.subject;
我想知道关于这个查询的关系代数。