例如,我有一个学生注册查询。如果某个特定模块有3个会话,则查询应该提示我有多少个会话,当我输入3时,其结果中应该出现三个新列。
这是我到目前为止所拥有的:
SELECT Mid(([firstname]),1) & " " & Mid(([surname]),1) AS Name,
tbl_trainers.Ministry, "_______________" AS [Day 1]
FROM tbl_trainers
INNER JOIN (tbl_sessions INNER JOIN tbl_trainer_sessions
ON tbl_sessions.session_id = tbl_trainer_sessions.SessionID)
ON tbl_trainers.trainerid = tbl_trainer_sessions.TrainerID
WHERE (((tbl_sessions.session_id)=[From Session ID]))
ORDER BY tbl_trainers.Ministry, tbl_sessions.session_id;