Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
subhaoviya
Posting Yak Master
135 Posts |
Posted - 2012-06-22 : 06:05:05
|
| Having 2 tables A and BA BC1 C11 12 25 36 4How to produce resultset C1123456 without using union operator |
|
|
waterduck
Aged Yak Warrior
982 Posts |
Posted - 2012-06-22 : 06:52:25
|
| select distinct case when a.c1 < b.c1 then b.c1 else a.c1 end from a a cross join (select * from b) b |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2012-06-23 : 00:04:29
|
| [code]select DISTINCT COALESCE(t1.C1,t2.C1) AS C1from table t1full join table t2on t2.C1 = t1.C1[/code]------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
|
|
|