摘要:
可以让你做很多事情,定义一个SQL片断,该SQL片断会被整个SQL语句所用到。作为提供数据的部分。代码例子: 1 with temp as 2 (select ID, Type_Name, Type_ID 3 from T_Base_GoodsType as t 4 where t.Shop_ID = @shop_id 5 and Type_ID = @Goods_TypeID 6 union all 7 select t1.ID, t1.Type_Name, t1.Type_ID 8 from T_Base_GoodsType as t1 9 ...
阅读全文