我总是犯这个错误 " The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE operator"
在sql上运行这行代码时--我希望获得的姓名,文本和最后的作者考虑他们最近的作品。
Select PR1.Name, PR1.TText, PR1.Author as Last_Author
From PageRevision as PR1, PageRevision as PR2
Group by Pr1.Name, PR1.TText
Having PR1.DDate = max(PR2.DDate);
1条答案
按热度按时间lhcgjxsq1#
看来最简单的方法就是这么做。