0% found this document useful (0 votes)
51 views1 page

Gssu

The document contains two SQL queries. The first query selects vendor data from various supplier tables and filters for active suppliers. The second query selects customer data from customer tables and filters for active customers. Both queries join data from party, registration, and account tables to retrieve identification, registration, and organizational information for the entities.

Uploaded by

Oracle developer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
51 views1 page

Gssu

The document contains two SQL queries. The first query selects vendor data from various supplier tables and filters for active suppliers. The second query selects customer data from customer tables and filters for active customers. Both queries join data from party, registration, and account tables to retrieve identification, registration, and organizational information for the entities.

Uploaded by

Oracle developer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

select

c.VENDOR_NAME,c.SEGMENT1,a.SUPPLIER_FLAG,a.PARTY_ID,a.PARTY_SITE_ID,a.ORG_ID,PARTY_
REG_LINE_ID,LINE_CONTEXT,REGISTRATION_TYPE_CODE,REGISTRATION_NUMBER,SEC_REGISTRATIO
N_TYPE_CODE,SECONDARY_REGISTRATION_NUMBER
from JAI_PARTY_REGS A,jai_party_reg_lines B, ap_suppliers
c,ap_supplier_sites_all d
where A.PARTY_REG_ID=B.PARTY_REG_ID
AND PARTY_TYPE_CODE='THIRD_PARTY_SITE'
AND SUPPLIER_FLAG='Y'
and EFFECTIVE_TO is null
and a.ORG_ID <> 0
and REGIME_ID<>5
and a.PARTY_SITE_ID is not null
and a.PARTY_ID=c.vendor_id
and c.vendor_id = d.vendor_id
and a.party_site_id=d.vendor_site_id

select
C.customer_name,CUSTOMER_NUMBER,a.customer_FLAG,a.PARTY_ID,a.PARTY_SITE_ID,a.ORG_ID
,PARTY_REG_LINE_ID,LINE_CONTEXT,REGISTRATION_TYPE_CODE,REGISTRATION_NUMBER,SEC_REGI
STRATION_TYPE_CODE,SECONDARY_REGISTRATION_NUMBER
from JAI_PARTY_REGS A,jai_party_reg_lines B, ar_customers
C,hz_cust_acct_sites_all D
where A.PARTY_REG_ID=B.PARTY_REG_ID
AND PARTY_TYPE_CODE='THIRD_PARTY_SITE'
AND CUSTOMER_FLAG='Y'
and EFFECTIVE_TO is null
and a.ORG_ID <> 0
and REGIME_ID<>5
and a.PARTY_SITE_ID is not null
AND A.PARTY_ID=C.CUSTOMER_ID
AND C.customer_id = D.cust_account_id
AND a.PARTY_SITE_ID=D.cust_acct_site_id
AND D.org_id = A.ORG_ID
AND C.status = 'A'
AND D.status = 'A'

You might also like