1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

HOw to get customer???

Discussion in 'Oracle Apps Technical' started by sambhaji, Jan 24, 2014.

  1. sambhaji

    sambhaji Active Member

    Messages:
    62
    Likes Received:
    2
    Trophy Points:
    160
    Hi All,

    I want to know customer related to operating unit in r12 anybody has query???

    Please send more queries regarding relation between hz tables and customers & suppliers table!!


    Regards,
    Sambhaji
     
  2. neelambhumij

    neelambhumij Active Member

    Messages:
    51
    Likes Received:
    2
    Trophy Points:
    160
    Location:
    JOHANNESBURG
    Hi

    Please check if the following query completes your requirements about customer.

    select distinct
    hp.party_name "Customer Name",
    hou.name "Organization",
    hca.account_number,
    hca.status,
    hl.address1,
    hl.address2,
    hl.address3,
    hl.city,
    hl.state,
    hl.postal_code
    from apps.hz_parties hp,
    apps.hz_cust_accounts hca,
    apps.hz_party_sites hps,
    apps.hz_customer_profiles hcp,
    apps.hz_locations hl,
    apps.ar_payment_schedules_all psa,
    --apps.hz_cust_site_uses hcsu
    apps.hz_cust_site_uses_all hcsu,
    apps.hr_operating_units hou
    where hp.party_id = hca.party_id(+)
    and hp.party_id = hcp.party_id
    and hp.party_id = hps.party_id
    and hps.location_id = hl.location_id
    and hca.cust_account_id = hcp.cust_account_id
    and hca.cust_account_id = psa.customer_id
    and psa.customer_site_use_id = hcsu.site_use_id
    and hcsu.org_id = hou.organization_id


    Thanx

    Kind Regards
    Neelam