if object_id('tempdb.dbo.#tb1') is not null drop table #tb1
go
create table #tb1([blu1] varchar(2))
insert #tb1
select '05' union all
select '06' union all
select '07'
if object_id('tempdb.dbo.#tb2') is not null drop table #tb2
go
create table #tb2([blu2] varchar(2))
insert #tb2
select '09' union all
select '12'
--> 测试数据
select rtrim(a.blu1)+ltrim(b.blu2) as [结果]
from #tb1 a,#tb2 b
想要的结果是
请指点如何修改语句,谢谢。
...全文
1487打赏收藏
急用:如何增加空格?
--> 建立数据表 if object_id('tempdb.dbo.#tb1') is not null drop table #tb1 go create table #tb1([blu1] varchar(2)) insert #tb1 select '05' union all select '06' union all select '07' if object_id('tempdb.dbo.#tb2') is not null drop table #tb2 go create ta