Monday, February 12, 2018

Query to get the customer name,account number,transaction number,receipt and amount detail

select hca.account_number,
       hp.party_name,
       rcta.trx_number,
       acra.receipt_number,
       rcta.trx_date,
       acra.creation_date,
       acra.amount
from hz_parties hp,
     hz_cust_accounts hca,
     ra_customer_trx_all rcta,
     ar_cash_receipts_all acra,
     ar_receivable_applications_all araa
where hp.party_id = hca.party_id
and rcta.sold_to_customer_id = hca.cust_account_id
and araa.cash_receipt_id = acra.cash_receipt_id
and araa.applied_customer_trx_id = rcta.customer_trx_id
and account_number = '&account_number';

No comments:

Post a Comment