I have five tables say T1,T2,T3,T4,T5. Each table has different columns say like T1 has T1CL1,T1CL2,T1CL3
and Table T2 has T2CL1,T2CL2,T2CL3 and so on...
Now I want to Create a Stored procedure selecting only few columns from Each table and it should return everything in only one Dataset. Is it possible? If Yes... This is what I tried and didn't get anything I want.
Select T1CL1,T1CL2 from T1 where T1CL3 = 'Something'
Select T2CL1,T2CL3 from T2 where T1CL2 = 'prm1'
Select T3CL3,T3CL4 from T3 where T3CL2 = 'prm2'
Select T4CL1,T4CL3 from T4 where T4CL2 = 'prm3'
Select T5CL1,T5CL3 from T5 where T1CL2 = 'prm4'
But I don't know how save the data from each query and place everything from SP into a Dataset?
Can anyone help me with this Please
Your help is much appreciated.
modified 18-Feb-15 10:01am.