我在下面有一个查询,它显示了这些结果:
SELECT q.QuestionId, q.QuestionContent, an.Answer
FROM Answer an
INNER JOIN Question q ON q.AnswerId = an.AnswerId;
查询结果:
QuestionId QuestionContent Answer
1 Who are me and you B
1 Who are me and you D
2 Name these Cars A
2 Name these Cars B
2 Name these Cars E
3 What is 2+2 B
我想要做的是将相同 QuestionId 的答案合并在一起,因此结果如下所示:
QuestionId QuestionContent Answer
1 Who are me and you B D
2 Name these Cars A B E
3 What is 2+2 B
这可能吗?
谢谢