Ganesh M

Ganesh M

  • NA
  • 63
  • 54.6k

join without common field

Sep 28 2012 5:18 AM
I have three table
client table has following field

c_name c_amount c_date
tcs             1000   2012/30/01
cts             2000    2012/25/01
hcl             3000    2012/25/01

trainer table has following field

t_name t_amount t_date
tcs             500   2012/30/01
cts             100    2012/25/02
hcl             300    2012/25/02

expense table has following field

e_name e_amount e_date
travelling             5000   2012/30/01
food                   1000    2012/25/01
others                1500    2012/25/02


Above three table has no common column or no primary key foreign key relation ship

how to get join three tables

i want month wise result like below

c_name c_amount c_date          t_name t_amount t_date         e_name e_amount e_date
tcs             1000   2012/30/01   tcs             500   2012/30/01   travelling             5000   2012/30/01
food                   1000    2012/25/01
cts             2000    2012/25/01
hcl             3000    2012/25/01


Answers (3)