我想知道就数据库系统而言,在哪些情况下最好使用多级索引或任何索引。如果我以以下架构为例:
Course (course_code, course_name, course_leader)
Module (module_code, module_name, module_leader, semester)
Course_module (course_code, module_code)
Lecturer (employee_id, employee_name, email, phone)
可以对行数和访问类型进行假设。我只想知道何时使用主索引而不是多级或二级索引等是正确的。