您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

SQL with as

2024/5/26 22:36:10发布22次查看
with temp as( select *from tb_order where auditing=2 and auditingtime='2013-04-01' and flag=2 ) select *from temp where ebayaccountid=21 相当于临时表 temp 分析器可以智能提示 临时表却不能。 临时表 select * into #temp from tb_order where aud
with temp as(
select *from tb_order where auditing=2 and auditingtime>='2013-04-01' and flag=2
)
select *from temp where ebayaccountid=21
相当于临时表 temp 分析器可以智能提示 临时表却不能。
 临时表
select * into #temp from tb_order where auditing=2 and auditingtime>='2013-04-01' and flag=2
select * from #temp where ebayaccountid=21
declare @flag int=2;
with temp as(
select *from tb_order where auditing=2 and auditingtime>='2013-04-01' and flag=@flag
)
select *from temp where ebayaccountid=21
declare @flag int=2; 这里的分号不可少 否则会报错
关键字 'with' 附近有语法错误。如果此语句是公用表表达式、xmlnamespaces 子句或者更改跟踪上下文子句,香港服务器,香港虚拟主机,那么前一个语句必须以分号结尾。
,香港空间
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product