0

世界上可能有什么问题,语法看起来不错:

With photos(PhotoID, MemberID) as
(
    select  photoID,
            memberID
    from MemberPhotos
)
select PhotoID, MemberID from photos
4

1 回答 1

3

如果CTE来自另一个查询,您应该在关键字semi-colon之前添加一个。WITH

;With photos(PhotoID, MemberID) as
(
    select  photoID,
            memberID
    from MemberPhotos
)
select PhotoID, MemberID from photos
于 2012-11-08T03:57:00.480 回答