select top 10* from B_goodsPara a,b_goods b,B_ShopGoods c where a.GOODSSKU=b.SKU AND a.SHOPSKU=c.SKU and b.GoodsStatus='在售' and b.NID not in (select top 1 NID from b_goods order by NID)
求改良,谢谢,在线等
SELECT * FROM ARTICLE w1,
(
SELECT TOP 30 ID FROM
(
SELECT TOP 1030 ID, YEAR FROM ARTICLE ORDER BY YEAR DESC, ID DESC
) w ORDER BY w.YEAR ASC, w.ID ASC
) w2 WHERE w1.ID = w2.ID ORDER BY w1.YEAR DESC, w1.ID DESC
仿照这个来写