ms sql :select * from (select *from b) as xxx where 和 select * from (select *from b) xxx where区select * from (select *from b) as xxx where…… 和 select * from (select *from b) xxx where……的区别别告诉我是一样的.因为我有一
来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/21 22:59:56
ms sql :select * from (select *from b) as xxx where 和 select * from (select *from b) xxx where区select * from (select *from b) as xxx where…… 和 select * from (select *from b) xxx where……的区别别告诉我是一样的.因为我有一
ms sql :select * from (select *from b) as xxx where 和 select * from (select *from b) xxx where区
select * from (select *from b) as xxx where…… 和 select * from (select *from b) xxx where……的区别
别告诉我是一样的.
因为我有一个存储过程
set @query= 'select *
from (select Food.*,Supplier.SupplierName,Row_number()over( '+@orderQuery+' ) as IDRank from '+@tableName+' ' +@checkQuery+' ) xx
where xx.IDRank between ……(省略了)'
这个是对的.
我改成
set @query= 'select *
from (select Food.*,Supplier.SupplierName,Row_number()over( '+@orderQuery+' ) as IDRank from '+@tableName+' ' +@checkQuery+' ) as xx
where IDRank between……(省略了)‘
之后,也可以执行
但是如果改为
set @query= 'select *
from (select Food.*,Supplier.SupplierName,Row_number()over( '+@orderQuery+' ) as IDRank from '+@tableName+' ' +@checkQuery+' )
where IDRank between……(省略了)‘
就不能执行了
ms sql :select * from (select *from b) as xxx where 和 select * from (select *from b) xxx where区select * from (select *from b) as xxx where…… 和 select * from (select *from b) xxx where……的区别别告诉我是一样的.因为我有一
select * from (select *from b) as xxx where
select * from (select *from b) xxx where
确实是一样的,但是第三句相当于
select * from (select *from b) where
这个有错误.