Hi,
I have two tables called header user, inbox. The table structures mentioned below,
User:
NUM_USER VCH_NAME VCH_PHONE_NO VCH_STATUS
1 XXXX 123 Y
2 YYYY 321 Y
3 ZZZZ 456 Y
INBOX
NUM_ID(P.K) NUM_CUST_ID NUM_SEND_CALL_ID NUM_REC_CAL_ID DTT_DATE
1 10 2 1 4/11/2014
2 10 3 2 4/11/2014
3 10 3 4/11/2014
4 10 1 4/11/2014
* NUM_SEND_CALL_ID, NUM_REC_CAL_ID ARE FOREIGN KEY REFERENCES USER TABLE
Now I want to map Inbox table, user table and get the result below mentioned form,
ID (Inbox) Sendername(User table vch_name) Receivedusername (user tablevch_name )
1 YYYY XXXX
2 ZZZZ YYYY
3 ZZZZ
4 XXXX
Please give some suggestion to achieve my result.