create proc sp_AA
@table varchar(100)
as
exec('select * from A where A.f1 in (select f1 from '+@table+') a')
go
@table varchar(100)
as
exec('select * from A where A.f1 in (select f1 from '+@table+') a')
go
调试欢乐多
@table varchar(10)
as
exec('select * from A where A.f1 in (select f1 from '+ @table+')')
@table varchar(100)
as
exec('select * from A where A.f1 in (select f1 from '+@table+')')
@sql varchar(100)
as
exec('select * from A where A.f1 in '+@sql)
@sql varchar(100)
as
exec('select * from A where A.f1 in ('+@sql+')')