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 |
|
imrul
Starting Member
36 Posts |
Posted - 2011-06-05 : 08:56:25
|
| I have following two tablesTable_1Mem_Id Trx_Dt Amount------------------------------1 2011-01-01 100001 2011-01-15 5000Table_2Mem_Id Trx_Dt Amount---------------------------------1 2011-01-06 01 2011-01-16 1501 2011-01-18 1501 2011-01-24 2501 2011-01-29 100I need the Output like bellow, without using the UNION operatorMem_Id Trx_Dt T_1Amount T_2 Amount-------------------------------------------------------1 2011-01-01 0 100001 2011-01-06 0 01 2011-01-15 0 50001 2011-01-16 150 0 1 2011-01-18 150 01 2011-01-24 250 01 2011-01-29 100 01. Trx_Dt will be combined from both table and will be in an sequential order.2. Amount from two tables will in two different columnCan any one help? |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2011-06-05 : 09:05:01
|
| is this a homework question? also why you want solution without using union?------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
|
|
|