DBA Data[Home] [Help]

APPS.OKS_FULFILL SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 76

       SELECT hdr.id id
           ,  line.id line_id
       FROM
                OKC_K_GRPINGS        okg
               ,OKC_K_PARTY_ROLES_B  okp
               ,OKC_K_HEADERS_B      Hdr
               ,OKC_STATUSES_B      st
	       ,OKC_K_LINES_B       line
        Where  Hdr.scs_code = 'SUBSCRIPTION'
        And    Hdr.Template_yn = 'N'
        And    Hdr.sts_code = st.CODE
        AND    st.ste_code in ('ACTIVE','SIGNED','EXPIRED','TERMINATED')
        AND    hdr.sts_code <> 'QA_HOLD'
        And    Hdr.authoring_org_id = NVL(p_org_id, Hdr.authoring_org_id)
        And    okp.chr_id   =  hdr.id
        And    line.dnz_chr_id = Hdr.id
        And    line.lse_id = 46
        And    okp.rle_code = 'SUBSCRIBER'
        And    okp.object1_id1 = nvl(p_customer_id,okp.object1_id1)
        And    okg.included_chr_id = hdr.id
        And    okg.cgp_parent_id = nvl(p_grp_id,okg.cgp_parent_id)
        And    EXISTS  (Select 1 from  OKS_SUBSCR_ELEMENTS  sub
 	                          Where     sub.dnz_chr_id = hdr.id
 	                          And    sub.dnz_cle_id = line.id
 	                          And    sub.order_header_id  is null)
      /* Commented by sjanakir for Bug# 5568285 (FP Bug for 5442268) */
      /* Order By  hdr.id ; */
Line: 107

       SELECT hdr.id id
            , line.id line_id
       FROM
               OKC_K_HEADERS_B      Hdr
               ,OKC_STATUSES_B      st
               ,OKC_K_LINES_B       line
        Where  Hdr.scs_code = 'SUBSCRIPTION'
        And    Hdr.Template_yn = 'N'
        And    Hdr.sts_code = st.CODE
        AND    st.ste_code in ('ACTIVE','SIGNED','EXPIRED','TERMINATED')
        AND    Hdr.sts_code <> 'QA_HOLD'
	And    line.dnz_chr_id = Hdr.id
        And    line.lse_id = 46
	And    EXISTS  (Select 1 from  OKS_SUBSCR_ELEMENTS  sub
 	                          Where     sub.dnz_chr_id = hdr.id
 	                          And    sub.dnz_cle_id = line.id
 	                          And    sub.order_header_id  is null)
        Order By  hdr.id ;
Line: 352

        Select min(hdr.id) minid,
			   max(hdr.id) maxid,
			   avg(hdr.id) avgid,
			   stddev(hdr.id) stdid,
			   count(*) total
        From
                OKC_K_GRPINGS        okg
               ,OKC_K_PARTY_ROLES_B  okp
	       ,OKC_K_HEADERS_B Hdr
               ,OKC_STATUSES_B ST
        Where  Hdr.scs_code = 'SUBSCRIPTION'
        And    Hdr.Template_yn = 'N'
        And    Hdr.sts_code = st.CODE
        AND    st.ste_code in ('ACTIVE','SIGNED','EXPIRED','TERMINATED')
        AND    hdr.sts_code <> 'QA_HOLD'
	And    Hdr.authoring_org_id = NVL(p_org_id, Hdr.authoring_org_id)
        And    okp.chr_id   =  hdr.id
        And    okp.rle_code = 'SUBSCRIBER'
        And    okp.object1_id1 = nvl(p_customer_id,okp.object1_id1)
        And    okg.included_chr_id = hdr.id
        And    okg.cgp_parent_id = nvl(p_grp_id,okg.cgp_parent_id)
	And     EXISTS  (Select 1 from  OKS_SUBSCR_ELEMENTS  sub
         	 	 Where  sub.dnz_chr_id = hdr.id
                          And    sub.order_header_id  is null);
Line: 378

        Select min(hdr.id) minid,
			   max(hdr.id) maxid,
			   avg(hdr.id) avgid,
			   stddev(hdr.id) stdid,
			   count(*) total
        From
               OKC_K_HEADERS_B Hdr
               ,OKC_STATUSES_B ST
        Where  Hdr.scs_code = 'SUBSCRIPTION'
        And    Hdr.Template_yn = 'N'
        And    Hdr.sts_code = st.CODE
	AND    st.ste_code in ('ACTIVE','SIGNED','EXPIRED','TERMINATED')
        AND    hdr.sts_code <> 'QA_HOLD'
	And     EXISTS  (Select 1 from  OKS_SUBSCR_ELEMENTS  sub
         	 	 Where     sub.dnz_chr_id = hdr.id
                         And    sub.order_header_id  is null);