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 |
|
sudha12345
Starting Member
47 Posts |
Posted - 2009-04-25 : 02:43:36
|
| i has one requirement that i want to display data b taking union of allfor exserverid customeridp1 i1p2 i2p3 i3p4 i4select * from table where serverid = p1 and customerid =i1unionselect * from table where serverid = p2 and cusomerid = i2unionselect * from table where serverid =p3 and customerid = i3unionselect * from table where serverid =p4 and customerid = i4is there any solution for this? if there please help meSudhakar |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2009-04-25 : 03:14:11
|
| hi sudhakar, wat u really want to achieve?can u explain a little more..using union will delete duplicate records..tanx... |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-04-25 : 03:14:45
|
| Can you post some sample data with expected result?MadhivananFailing to plan is Planning to fail |
 |
|
|
sudha12345
Starting Member
47 Posts |
Posted - 2009-04-25 : 03:21:01
|
quote: Originally posted by soorajtnpki hi sudhakar, wat u really want to achieve?can u explain a little more..using union will delete duplicate records..tanx...
i has a report that i will take different serverids and different customerids.so as i told there was data above, what we planned is to takethe serverids and customerids individully and compare the results between them.for ex :serverid customerid valuep1 i1 20p2 i2 34p3 i3 45p4 i4 80so we planned to take individually both the serverids and customeridsand then compare the dataSudhakar |
 |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2009-04-25 : 04:34:02
|
| ok then pls reply ur expected outputtanx.. |
 |
|
|
|
|
|