DBA Data[Home] [Help]

APPS.OKL_SEEDED_FUNCTIONS_PVT dependencies on OKL_STREAMS

Line 115: FROM okl_strm_elements STRE, OKL_STREAMS STR

111:
112: CURSOR c_total_amount_paid (p_sty_id NUMBER)
113: IS
114: SELECT COUNT(*)
115: FROM okl_strm_elements STRE, OKL_STREAMS STR
116: WHERE STR.ID = STRE.STM_ID
117: AND STR.STY_ID = p_sty_id
118: AND STRE.DATE_BILLED IS NOT NULL
119: AND STR.KHR_ID = p_contract_id

Line 195: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

191: -- cursor fetch replaced with the streams util call, change
192: -- done for user defined streams impacts, bug 3924300
193: -- begin changes for bug 3924300
194:
195: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
196: 'INSURANCE_RECEIVABLE',
197: l_return_status,
198: l_stm_type_id);
199: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

Line 424: okl_streams str,

420: CURSOR l_line_rents_csr (chrId NUMBER ) IS
421: SELECT NVL(str.link_hist_stream_id,-1) link_hist_stream_id,
422: NVL(SUM(sele.amount),0) amount
423: FROM okl_strm_elements sele,
424: okl_streams str,
425: --okl_strm_type_tl sty,
426: okl_strm_type_v sty,
427: okl_K_lines_full_v kle,
428: okc_statuses_b sts

Line 453: okl_streams str,

449:
450: CURSOR l_chr_rents_csr (chrId NUMBER ) IS
451: SELECT NVL(SUM(sele.amount),0) amount
452: FROM okl_strm_elements sele,
453: okl_streams str,
454: --okl_strm_type_tl sty
455: okl_strm_type_v sty
456: WHERE sele.stm_id = str.id
457: AND str.sty_id = sty.id

Line 551: okl_streams str,

547: -- "Not being used" and hence not modified with its purpose
548: --
549: SELECT NVL(SUM(sele.amount),0) INTO l_income
550: FROM okl_strm_elements sele,
551: okl_streams str,
552: okl_strm_type_v sty,
553: okl_K_lines_full_v kle,
554: okc_statuses_b sts
555: WHERE sele.stm_id = str.id

Line 3335: -- OKL_STREAMS stm,

3331: -- Bug 5055714. Commenting below derivation. Using utility provided instead.
3332: -- CURSOR principal_bal_csr(p_ctr_id NUMBER, p_start_date DATE, p_end_date DATE, p_prin_bal_id NUMBER) IS
3333: -- SELECT SUM(ste.amount)
3334: -- FROM OKL_STRM_TYPE_B sty,
3335: -- OKL_STREAMS stm,
3336: -- OKL_STRM_ELEMENTS ste
3337: -- WHERE stm.khr_id = p_ctr_id
3338: -- AND stm.active_yn = 'Y'
3339: -- AND stm.say_code = 'CURR'

Line 3350: -- OKL_STREAMS stm,

3346: -- for given period is not found
3347: -- CURSOR prior_prin_bal_csr(p_ctr_id NUMBER, p_start_date DATE, p_prin_bal_id NUMBER) IS
3348: -- SELECT SUM(ste.amount)
3349: -- FROM OKL_STRM_TYPE_B sty,
3350: -- OKL_STREAMS stm,
3351: -- OKL_STRM_ELEMENTS ste
3352: -- WHERE stm.khr_id = p_ctr_id
3353: -- AND stm.active_yn = 'Y'
3354: -- AND stm.say_code = 'CURR'

Line 3360: -- OKL_STREAMS stm,

3356: -- AND stm.sty_id = sty.id
3357: -- AND ste.stm_id = stm.id
3358: -- AND ste.stream_element_date = (SELECT MAX(stream_element_date)
3359: -- FROM OKL_STRM_TYPE_B sty,
3360: -- OKL_STREAMS stm,
3361: -- OKL_STRM_ELEMENTS ste
3362: -- WHERE stm.khr_id = p_ctr_id
3363: -- AND stm.active_yn = 'Y'
3364: -- AND stm.say_code = 'CURR'

Line 3424: -- OKL_STREAMS_UTIL.get_dependent_stream_type(

3420:
3421: -- SGIYER
3422: -- UDS Impact
3423: -- Bug 5055714.
3424: -- OKL_STREAMS_UTIL.get_dependent_stream_type(
3425: -- p_khr_id => p_khr_id,
3426: -- p_primary_sty_purpose => 'RENT',
3427: -- p_dependent_sty_purpose => 'PRINCIPAL_BALANCE',
3428: -- x_return_status => l_return_status,

Line 3537: FROM OKL_STREAMS stm,

3533: -- SGIYER
3534: -- modifying cursor for user defind streams project
3535: CURSOR get_unb_rec_csr(p_ctr_id NUMBER, p_date DATE, p_sty_id NUMBER) IS
3536: SELECT SUM(ste.amount)
3537: FROM OKL_STREAMS stm,
3538: OKL_STRM_ELEMENTS ste,
3539: OKL_STRM_TYPE_B sty
3540: WHERE stm.khr_id = p_ctr_id
3541: AND stm.sty_id = sty.id

Line 3581: OKL_STREAMS_UTIL.get_primary_stream_type(

3577: END IF;
3578:
3579: -- SGIYER
3580: -- UDS Impact
3581: OKL_STREAMS_UTIL.get_primary_stream_type(
3582: p_khr_id => p_khr_id,
3583: p_primary_sty_purpose => 'RENT',
3584: x_return_status => l_return_status,
3585: x_primary_sty_id => l_sty_id);

Line 3662: FROM OKL_STREAMS stm,

3658: -- on product management's instructions.
3659: -- SGIYER. User defined streams project changes.09/22/04
3660: CURSOR get_unearn_rev_csr (p_ctr_id NUMBER, p_date DATE, p_rent_sty_id NUMBER, p_lease_inc_sty_id NUMBER) IS
3661: SELECT SUM(ste.amount)
3662: FROM OKL_STREAMS stm,
3663: OKL_STRM_ELEMENTS ste,
3664: OKL_STRM_TYPE_B sty
3665: WHERE stm.khr_id = p_ctr_id
3666: AND stm.sty_id = sty.id

Line 3673: FROM OKL_STREAMS stm,

3669: AND stm.say_code = 'CURR'
3670: AND ste.stm_id = stm.id
3671: AND ste.stream_element_date >=
3672: (SELECT TRUNC(MIN(ste.stream_element_date),'MM')
3673: FROM OKL_STREAMS stm,
3674: OKL_STRM_ELEMENTS ste,
3675: OKL_STRM_TYPE_B sty
3676: WHERE stm.khr_id = p_ctr_id
3677: AND stm.sty_id = sty.id

Line 3685: FROM OKL_STREAMS stm,

3681: AND ste.stream_element_date >= p_date
3682: AND ste.date_billed IS NULL)
3683: AND ste.stream_element_date <=
3684: (SELECT LAST_DAY(MAX(ste.stream_element_date))
3685: FROM OKL_STREAMS stm,
3686: OKL_STRM_ELEMENTS ste,
3687: OKL_STRM_TYPE_B sty
3688: WHERE stm.khr_id = p_ctr_id
3689: AND stm.sty_id = sty.id

Line 3727: OKL_STREAMS_UTIL.get_primary_stream_type(

3723: END IF;
3724:
3725: -- SGIYER
3726: -- UDS Impact
3727: OKL_STREAMS_UTIL.get_primary_stream_type(
3728: p_khr_id => p_khr_id,
3729: p_primary_sty_purpose => 'RENT',
3730: x_return_status => l_return_status,
3731: x_primary_sty_id => l_rent_sty_id);

Line 3742: OKL_STREAMS_UTIL.get_dependent_stream_type(

3738: END IF;
3739:
3740: -- SGIYER
3741: -- UDS Impact
3742: OKL_STREAMS_UTIL.get_dependent_stream_type(
3743: p_khr_id => p_khr_id,
3744: p_primary_sty_purpose => 'RENT',
3745: p_dependent_sty_purpose => 'LEASE_INCOME',
3746: x_return_status => l_return_status,

Line 3894: OKL_STREAMS stm

3890: CURSOR unaccrued_subsidy_csr(p_ctr_id OKL_K_HEADERS_FULL_V.ID%TYPE, p_date DATE, p_subsidy_inc_id NUMBER) IS
3891: SELECT SUM(ste.amount)
3892: FROM OKL_STRM_ELEMENTS ste,
3893: OKL_STRM_TYPE_B sty,
3894: OKL_STREAMS stm
3895: WHERE stm.khr_id = p_ctr_id
3896: AND stm.sty_id = sty.id
3897: AND sty.id = p_subsidy_inc_id
3898: AND stm.active_yn = 'Y'

Line 3938: OKL_STREAMS_UTIL.get_dependent_stream_type(

3934: END IF;
3935:
3936: -- Bug 4053623.
3937: -- Modifying error handling.
3938: OKL_STREAMS_UTIL.get_dependent_stream_type(
3939: p_khr_id => p_khr_id,
3940: p_primary_sty_purpose => 'SUBSIDY',
3941: p_dependent_sty_purpose => 'SUBSIDY_INCOME',
3942: x_return_status => l_return_status,

Line 4112: OKL_STREAMS_UTIL.get_dependent_stream_type(

4108: p_msg_name => 'OKL_REV_LPV_CNTRCT_NUM_ERROR');
4109: RAISE OKL_API.G_EXCEPTION_ERROR;
4110: END IF;
4111:
4112: OKL_STREAMS_UTIL.get_dependent_stream_type(
4113: p_khr_id => p_khr_id,
4114: p_primary_sty_purpose => 'RENT',
4115: p_dependent_sty_purpose => 'ACTUAL_INCOME_ACCRUAL',
4116: x_return_status => l_return_status,

Line 4797: FROM okl_streams stm,

4793: cp_contract_id NUMBER,
4794: cp_contract_line_id NUMBER,
4795: cp_stream_type_id NUMBER) IS
4796: SELECT SUM (NVL (ste.amount, 0)) amount_due
4797: FROM okl_streams stm,
4798: okl_strm_type_b sty, -- SECHAWLA 04-MAR-03 Added this table to get the billable_yn flag
4799: okl_strm_elements ste
4800: WHERE stm.khr_id = cp_contract_id
4801: AND stm.kle_id = cp_contract_line_id

Line 4898: FROM okl_streams stm,

4894: cp_contract_id NUMBER,
4895: cp_contract_line_id NUMBER,
4896: cp_stream_type_id NUMBER) IS
4897: SELECT SUM (NVL (ste.amount, 0)) amount_due
4898: FROM okl_streams stm,
4899: okl_strm_type_b sty, -- SECHAWLA 04-MAR-03 Added this table to get the billable_yn flag
4900: okl_strm_elements ste
4901: WHERE stm.khr_id = cp_contract_id
4902: AND stm.kle_id = cp_contract_line_id

Line 4922: FROM okl_streams stm,

4918: cp_contract_line_id NUMBER,
4919: cp_stream_type_id NUMBER,
4920: cp_trx_date DATE) IS
4921: SELECT SUM (NVL (ste.amount, 0)) amount_due
4922: FROM okl_streams stm,
4923: okl_strm_type_b sty,
4924: okl_strm_elements ste
4925: WHERE stm.khr_id = cp_contract_id
4926: AND stm.kle_id = cp_contract_line_id

Line 4951: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

4947: BEGIN
4948: --PAGARG 31-Dec-2004 Bug# 4097591 Start
4949: --UDS impact. Obtain stream type id and pass it to cursor
4950:
4951: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
4952: 'RENT',
4953: l_return_status,
4954: l_stream_type_id);
4955:

Line 5185: okl_streams stm,

5181: --Instead of using stream name, join the sty id passed to cursor
5182: CURSOR line_csr (c_contract_line_id NUMBER, p_sty_id NUMBER) IS
5183: SELECT NVL(SUM(sel.amount),0)
5184: FROM okl_strm_elements sel,
5185: okl_streams stm,
5186: okl_strm_type_v sty
5187: WHERE sty.id = p_sty_id
5188: AND stm.sty_id = sty.id
5189: AND stm.say_code = 'CURR'

Line 5205: okl_streams stm,

5201: --Instead of using stream name, join the sty id passed to cursor
5202: CURSOR line_reporting_csr (c_contract_line_id IN NUMBER, cp_trx_date IN DATE, p_sty_id NUMBER) IS
5203: SELECT NVL(SUM(sel.amount),0)
5204: FROM okl_strm_elements sel,
5205: okl_streams stm,
5206: okl_strm_type_v sty
5207: WHERE sty.id = p_sty_id
5208: AND stm.sty_id = sty.id
5209: AND stm.say_code = 'CURR' -- reporting streams are current

Line 5260: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,

5256: p_contract_id => p_contract_id,
5257: x_rep_product_id => lx_rep_product_id);
5258:
5259:
5260: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,
5261: p_product_id => lx_rep_product_id,
5262: p_primary_sty_purpose => 'RENT',
5263: p_dependent_sty_purpose => 'LEASE_INCOME',
5264: x_return_status => l_return_status,

Line 5271: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,

5267: -- sechawla 05-dec-07 6671849 : END
5268:
5269: --PAGARG 31-Dec-2004 Bug# 4097591 Start
5270: --UDS impact. Obtain stream type id and pass it to cursor
5271: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,
5272: p_primary_sty_purpose => 'RENT',
5273: p_dependent_sty_purpose => 'LEASE_INCOME',
5274: x_return_status => l_return_status,
5275: x_dependent_sty_id => l_stream_type_id);

Line 5436: okl_streams str,

5432: CURSOR C (p_contract_id NUMBER)
5433: IS
5434: SELECT NVL(SUM(sele.amount),0)
5435: FROM okl_strm_elements sele,
5436: okl_streams str,
5437: okl_strm_type_v sty
5438: WHERE sele.stm_id = str.id
5439: AND str.sty_id = sty.id
5440: AND UPPER(sty.stream_type_purpose) = 'SECURITY_DEPOSIT'

Line 5498: FROM okl_streams_v asv,okl_strm_type_v bs,

5494:
5495: --Commented this code by rvaduri for bug 3487920
5496: /*
5497: SELECT NVL(SUM(cs.amount),0)
5498: FROM okl_streams_v asv,okl_strm_type_v bs,
5499: okl_strm_elements_v cs,
5500: okl_streams str,
5501: okl_strm_type_v sty
5502: WHERE cs.stm_id = asv.id AND bs.id = asv.sty_id

Line 5500: okl_streams str,

5496: /*
5497: SELECT NVL(SUM(cs.amount),0)
5498: FROM okl_streams_v asv,okl_strm_type_v bs,
5499: okl_strm_elements_v cs,
5500: okl_streams str,
5501: okl_strm_type_v sty
5502: WHERE cs.stm_id = asv.id AND bs.id = asv.sty_id
5503: AND str.sty_id = sty.id
5504: AND UPPER(sty.name) = 'RESIDUAL VALUE'

Line 5574: okl_streams str,

5570: CURSOR C (p_contract_id NUMBER)
5571: IS
5572: SELECT NVL(SUM(sele.amount),0)
5573: FROM okl_strm_elements sele,
5574: okl_streams str,
5575: okl_strm_type_v sty
5576: WHERE sele.stm_id = str.id
5577: AND str.sty_id = sty.id
5578: AND UPPER(sty.stream_type_purpose) = 'RENT'

Line 5591: okl_streams str,

5587: --Get all the future unbilled receivables for the line.
5588: CURSOR line (p_contract_id NUMBER, p_contract_line_id NUMBER) IS --sechawla 04-dec-08 : added p_contract_id
5589: SELECT NVL(SUM(sele.amount),0)
5590: FROM okl_strm_elements sele,
5591: okl_streams str,
5592: okl_strm_type_v sty
5593: WHERE sele.stm_id = str.id
5594: AND str.sty_id = sty.id
5595: --AND UPPER(sty.name) = 'RENT' --sechawla 04-dec-08 : remoevd

Line 5655: --okl_streams str, MGAAP 7263041

5651: CURSOR C (p_contract_id NUMBER)
5652: IS
5653: SELECT NVL(SUM(sele.amount),0)
5654: FROM okl_strm_elements sele,
5655: --okl_streams str, MGAAP 7263041
5656: okl_streams_rep_v str,
5657: okl_strm_type_v sty
5658: WHERE sele.stm_id = str.id
5659: AND str.sty_id = sty.id

Line 5656: okl_streams_rep_v str,

5652: IS
5653: SELECT NVL(SUM(sele.amount),0)
5654: FROM okl_strm_elements sele,
5655: --okl_streams str, MGAAP 7263041
5656: okl_streams_rep_v str,
5657: okl_strm_type_v sty
5658: WHERE sele.stm_id = str.id
5659: AND str.sty_id = sty.id
5660: AND UPPER(sty.stream_type_purpose) = 'LEASE_INCOME'

Line 5672: okl_streams str,

5668: --Commented by rvaduri for bug 3536862
5669: /*
5670: SELECT NVL(SUM(sele.amount),0)
5671: FROM okl_strm_elements sele,
5672: okl_streams str,
5673: okl_strm_type_v sty
5674: WHERE sele.stm_id = str.id
5675: AND str.sty_id = sty.id
5676: AND UPPER(sty.name) = 'UNEARNED INCOME'

Line 5688: --okl_streams str, MGAAP 7263041

5684:
5685: CURSOR line (p_contract_line_id NUMBER) IS
5686: SELECT NVL(SUM(sele.amount),0)
5687: FROM okl_strm_elements sele,
5688: --okl_streams str, MGAAP 7263041
5689: okl_streams_rep_v str,
5690: okl_strm_type_v sty
5691: WHERE sele.stm_id = str.id
5692: AND str.sty_id = sty.id

Line 5689: okl_streams_rep_v str,

5685: CURSOR line (p_contract_line_id NUMBER) IS
5686: SELECT NVL(SUM(sele.amount),0)
5687: FROM okl_strm_elements sele,
5688: --okl_streams str, MGAAP 7263041
5689: okl_streams_rep_v str,
5690: okl_strm_type_v sty
5691: WHERE sele.stm_id = str.id
5692: AND str.sty_id = sty.id
5693: AND UPPER(sty.name) = 'PRE-TAX INCOME'

Line 5705: okl_streams stm,

5701: /*
5702: *
5703: SELECT NVL(SUM(sel.amount),0)
5704: FROM okl_strm_elements sel,
5705: okl_streams stm,
5706: okl_strm_type_v sty
5707: WHERE sty.name = 'PRE-TAX INCOME'
5708: AND stm.sty_id = sty.id
5709: AND stm.say_code = 'CURR'

Line 5816: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;

5812: l_streams_repo_policy VARCHAR2(80); -- MGAAP 7263041
5813:
5814: BEGIN
5815:
5816: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;
5817:
5818: -- calculate asset line level depreciation
5819: IF(p_contract_line_id IS NOT NULL) THEN
5820: FOR p_asset_details_csr IN asset_details_csr(p_contract_line_id)

Line 5934: FROM okl_streams_v asv,okl_strm_type_v bs,

5930: /*
5931: CURSOR c (p_contract_id NUMBER)
5932: IS
5933: SELECT NVL(cs.amount,0)
5934: FROM okl_streams_v asv,okl_strm_type_v bs,
5935: okl_strm_elements_v cs,
5936: okl_streams str,
5937: okl_strm_type_v sty,
5938: okc_k_headers_v okh

Line 5936: okl_streams str,

5932: IS
5933: SELECT NVL(cs.amount,0)
5934: FROM okl_streams_v asv,okl_strm_type_v bs,
5935: okl_strm_elements_v cs,
5936: okl_streams str,
5937: okl_strm_type_v sty,
5938: okc_k_headers_v okh
5939: WHERE cs.stm_id = asv.id AND bs.id = asv.sty_id
5940: AND str.sty_id = sty.id

Line 5961: okl_streams stm,

5957: --It should be sum because we have to get the Principal balance on
5958: -- all the assets for the contract
5959: SELECT NVL(SUM(sel.amount),0)
5960: FROM okl_strm_elements sel,
5961: okl_streams stm,
5962: okl_strm_type_v sty
5963: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
5964: AND stm.sty_id = sty.id
5965: AND stm.say_code = 'CURR'

Line 5972: FROM okl_strm_elements sel,okl_streams stm,

5968: AND stm.khr_id = p_contract_id
5969: AND sel.stm_id = stm.id
5970: AND sel.stream_element_date =
5971: ( SELECT NVL(MAX(sel.stream_element_date), SYSDATE)
5972: FROM okl_strm_elements sel,okl_streams stm,
5973: okl_strm_type_v sty
5974: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
5975: AND stm.sty_id = sty.id
5976: AND stm.say_code = 'CURR'

Line 6153: okl_streams stm,

6149: --It should be sum because we have to get the Principal balance on
6150: -- all the assets for the contract
6151: SELECT NVL(SUM(sel.amount),0)
6152: FROM okl_strm_elements sel,
6153: okl_streams stm,
6154: okl_strm_type_v sty
6155: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
6156: AND stm.sty_id = sty.id
6157: AND stm.say_code = 'CURR'

Line 6164: FROM okl_strm_elements sel,okl_streams stm,

6160: AND stm.khr_id = p_contract_id
6161: AND sel.stm_id = stm.id
6162: AND sel.stream_element_date =
6163: ( SELECT NVL(MAX(sel.stream_element_date), SYSDATE)
6164: FROM okl_strm_elements sel,okl_streams stm,
6165: okl_strm_type_v sty
6166: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
6167: AND stm.sty_id = sty.id
6168: AND stm.say_code = 'CURR'

Line 6181: okl_streams stm,

6177:
6178: CURSOR line (p_contract_line_id NUMBER, p_date DATE) IS
6179: SELECT NVL(sel.amount,0)
6180: FROM okl_strm_elements sel,
6181: okl_streams stm,
6182: okl_strm_type_v sty
6183: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
6184: AND stm.sty_id = sty.id
6185: AND stm.say_code = 'CURR'

Line 6192: FROM okl_strm_elements sel,okl_streams stm,

6188: AND stm.kle_id = p_contract_line_id
6189: AND sel.stm_id = stm.id
6190: AND sel.stream_element_date =
6191: ( SELECT NVL(MAX(sel.stream_element_date), SYSDATE)
6192: FROM okl_strm_elements sel,okl_streams stm,
6193: okl_strm_type_v sty
6194: WHERE sty.stream_type_purpose = 'PRINCIPAL_BALANCE'
6195: AND stm.sty_id = sty.id
6196: AND stm.say_code = 'CURR'

Line 6445: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;

6441:
6442: l_streams_repo_policy VARCHAR2(80); -- MGAAP 7263041
6443: BEGIN
6444:
6445: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;
6446: -- calculate asset line level depreciation
6447: IF(p_contract_line_id IS NOT NULL) THEN
6448: FOR p_asset_details_csr IN asset_details_csr(p_contract_line_id)
6449: LOOP

Line 6586: okl_streams stm,

6582: SELECT sel.amount rent
6583: ,sel.stream_element_date due_date
6584: ,stm.kle_id
6585: FROM okl_strm_elements sel,
6586: okl_streams stm,
6587: okl_strm_type_v sty
6588: WHERE sty.stream_type_purpose = 'RENT'
6589: AND stm.sty_id = sty.id
6590: AND stm.say_code = 'CURR'

Line 6606: okl_streams stm,

6602: IS
6603: SELECT sel.amount rent
6604: ,sel.stream_element_date due_date
6605: FROM okl_strm_elements sel,
6606: okl_streams stm,
6607: okl_strm_type_v sty
6608: WHERE sty.stream_type_purpose = 'RENT'
6609: AND stm.sty_id = sty.id
6610: AND stm.say_code = 'CURR'

Line 7438: ,okl_streams stmb

7434: ,p_sty_id IN NUMBER)
7435: IS
7436: SELECT NVL(SUM(selb.amount),0) total_amount
7437: FROM okl_strm_elements selb
7438: ,okl_streams stmb
7439: ,okl_pool_contents pocb
7440: ,okl_strm_type_v styv --ankushar --Bug 6594724
7441: ,okc_k_headers_b chrb --ankushar --Bug 6594724
7442: WHERE stmb.khr_id = p_dnz_chr_id

Line 7490: ,okl_streams stmb

7486: ,p_sty_id IN NUMBER)
7487: IS
7488: SELECT NVL(SUM(selb.amount),0) total_amount
7489: FROM okl_strm_elements selb
7490: ,okl_streams stmb
7491: ,okl_pool_contents pocb
7492: WHERE stmb.khr_id = p_dnz_chr_id
7493: AND stmb.kle_id = p_kle_id
7494: AND stmb.sty_id = p_sty_id

Line 7586: ,okl_streams stmb

7582: CURSOR l_okl_pv_amounts_csr(p_sty_purpose IN VARCHAR2)
7583: IS
7584: SELECT NVL(SUM(selb.amount),0) total_amount
7585: FROM okl_strm_elements selb
7586: ,okl_streams stmb
7587: ,okl_strm_type_v styv
7588: ,okl_pool_contents pocb
7589: WHERE stmb.source_id = p_chr_id
7590: AND styv.stream_type_purpose = p_sty_purpose

Line 7603: ,okl_streams stmb

7599: CURSOR l_okl_pv_amounts_pending_csr(p_sty_purpose IN VARCHAR2)
7600: IS
7601: SELECT NVL(SUM(selb.amount),0) total_amount
7602: FROM okl_strm_elements selb
7603: ,okl_streams stmb
7604: ,okl_strm_type_v styv
7605: ,okl_pool_contents pocb
7606: WHERE stmb.source_id = p_chr_id
7607: AND styv.stream_type_purpose = p_sty_purpose

Line 7832: OKL_STREAMS STMB,

7828: -- mvasudev, 09/29/2004, Bug#3909240
7829: CURSOR c_rent_accrual(p_contract_id okc_k_headers_b.id%TYPE) IS
7830: SELECT NVL(SUM(SELB.AMOUNT),0)
7831: FROM
7832: OKL_STREAMS STMB,
7833: OKL_STRM_ELEMENTS SELB,
7834: OKL_STRM_TYPE_V STYV
7835: WHERE STMB.ID = SELB.STM_ID
7836: AND STMB.STY_ID = STYV.ID

Line 7855: OKL_STREAMS STMB,

7851:
7852: CURSOR c_rent_accrual_pending(p_contract_id okc_k_headers_b.id%TYPE) IS
7853: SELECT NVL(SUM(SELB.AMOUNT),0)
7854: FROM
7855: OKL_STREAMS STMB,
7856: OKL_STRM_ELEMENTS SELB,
7857: OKL_STRM_TYPE_V STYV
7858: WHERE STMB.ID = SELB.STM_ID
7859: AND STMB.STY_ID = STYV.ID

Line 8059: okl_streams stmb,

8055: SELECT
8056: NVL(SUM(NVL(selb.AMOUNT,0)),0) AMOUNT
8057: FROM
8058: okl_strm_type_v styv,
8059: okl_streams stmb,
8060: okl_strm_elements selb,
8061: okl_pool_contents pocb
8062: WHERE styv.stream_type_subclass = p_stm_sub_class
8063: AND styv.id = stmb.sty_id

Line 8080: okl_streams stmb,

8076: SELECT
8077: NVL(SUM(NVL(selb.AMOUNT,0)),0) AMOUNT
8078: FROM
8079: okl_strm_type_v styv,
8080: okl_streams stmb,
8081: okl_strm_elements selb,
8082: okl_pool_contents pocb
8083: WHERE styv.stream_type_subclass = p_stm_sub_class
8084: AND styv.id = stmb.sty_id

Line 8670: okl_streams str,

8666: ---------------------------------------------------
8667: CURSOR l_line_amortexp_csr (chrId NUMBER ) IS
8668: SELECT NVL(SUM(sele.amount),0) amount
8669: FROM okl_strm_elements sele,
8670: okl_streams str,
8671: --okl_strm_type_tl sty,
8672: okl_strm_type_v sty,
8673: okl_K_lines_full_v kle,
8674: okc_statuses_b sts

Line 8697: okl_streams str,

8693: -----------------------------------------------------
8694: CURSOR l_chr_amortexp_csr (chrId NUMBER) IS
8695: SELECT NVL(SUM(sele.amount),0) amount
8696: FROM okl_strm_elements sele,
8697: okl_streams str,
8698: --okl_strm_type_tl sty
8699: okl_strm_type_v sty
8700: WHERE sele.stm_id = str.id
8701: AND str.sty_id = sty.id

Line 8789: FROM okl_streams stm,

8785: cp_contract_line_id NUMBER,
8786: cp_date DATE,
8787: cp_sty_id NUMBER) IS
8788: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_due
8789: FROM okl_streams stm,
8790: okl_strm_type_b sty,
8791: okl_strm_elements ste
8792: ,okl_pool_contents pocb
8793: WHERE stm.khr_id = cp_contract_id

Line 8816: FROM okl_streams stm,

8812: cp_contract_line_id NUMBER,
8813: cp_sty_id NUMBER,
8814: cp_date DATE) IS --gboomina bug 4775555
8815: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_payable
8816: FROM okl_streams stm,
8817: okl_strm_type_b sty,
8818: okl_strm_elements ste
8819: ,okl_pool_contents pocb
8820: WHERE stm.khr_id = cp_contract_id

Line 8840: FROM okl_streams stm,

8836: cp_contract_line_id NUMBER,
8837: cp_date DATE,
8838: cp_sty_id NUMBER) IS
8839: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_due
8840: FROM okl_streams stm,
8841: okl_strm_type_b sty,
8842: okl_strm_elements ste
8843: ,okl_pool_contents pocb
8844: WHERE stm.khr_id = cp_contract_id

Line 8866: FROM okl_streams stm,

8862: cp_contract_line_id NUMBER,
8863: cp_sty_id NUMBER,
8864: cp_date DATE) IS
8865: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_payable
8866: FROM okl_streams stm,
8867: okl_strm_type_b sty,
8868: okl_strm_elements ste
8869: ,okl_pool_contents pocb
8870: WHERE stm.khr_id = cp_contract_id

Line 8943: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

8939: END IF;
8940:
8941: --PAGARG 19-Nov-2004 Bug# 4012614
8942: --UDS impact. Obtain stream type id and pass it to cursor
8943: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
8944: 'RENT',
8945: l_return_status,
8946: l_sty_id);
8947:

Line 8967: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,

8963: CLOSE l_unbill_stream_csr;
8964: END IF;
8965:
8966: --06-Dec-2004 PAGARG Bug# 3948473 Pass investor agreement id to obtain stream id
8967: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,
8968: 'INVESTOR_RENT_DISB_BASIS',
8969: l_return_status,
8970: l_sty_id);
8971:

Line 9060: FROM okl_streams stm,

9056: cp_contract_id NUMBER,
9057: cp_contract_line_id NUMBER,
9058: cp_sty_id NUMBER) IS
9059: SELECT NVL(SUM (NVL (ste.amount, 0)), 0) amount_due
9060: FROM okl_streams stm,
9061: okl_strm_type_b sty,
9062: okl_strm_elements ste,
9063: okl_pool_contents pocb
9064: WHERE stm.khr_id = cp_contract_id

Line 9085: FROM okl_streams stm,

9081: cp_contract_id NUMBER,
9082: cp_contract_line_id NUMBER,
9083: cp_sty_id NUMBER) IS
9084: SELECT NVL(SUM (NVL (ste.amount, 0)), 0) amount_due
9085: FROM okl_streams stm,
9086: okl_strm_type_b sty,
9087: okl_strm_elements ste,
9088: okl_pool_contents pocb
9089: WHERE stm.khr_id = cp_contract_id

Line 9116: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

9112: -- Calculate result
9113: -- ****************
9114: --PAGARG 19-Nov-2004 Bug# 4012614
9115: --UDS impact. Obtain stream type id and pass it to cursor
9116: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
9117: 'RESIDUAL_VALUE',
9118: l_return_status,
9119: l_sty_id);
9120:

Line 9211: FROM okl_streams stm,

9207: cp_contract_line_id NUMBER,
9208: cp_date DATE,
9209: cp_sty_id NUMBER) IS
9210: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_due
9211: FROM okl_streams stm,
9212: okl_strm_type_b sty,
9213: okl_strm_elements ste
9214: ,okl_pool_contents pocb
9215: WHERE stm.khr_id = cp_contract_id

Line 9236: FROM okl_streams stm,

9232: cp_contract_line_id NUMBER,
9233: cp_sty_id NUMBER,
9234: cp_date DATE) IS --gboomina bug 4775555
9235: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_payable
9236: FROM okl_streams stm,
9237: okl_strm_type_b sty,
9238: okl_strm_elements ste
9239: ,okl_pool_contents pocb
9240: WHERE stm.khr_id = cp_contract_id

Line 9259: FROM okl_streams stm,

9255: cp_contract_line_id NUMBER,
9256: cp_date DATE,
9257: cp_sty_id NUMBER) IS
9258: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_due
9259: FROM okl_streams stm,
9260: okl_strm_type_b sty,
9261: okl_strm_elements ste,
9262: okl_pool_contents pocb
9263: WHERE stm.khr_id = cp_contract_id

Line 9284: FROM okl_streams stm,

9280: cp_contract_line_id NUMBER,
9281: cp_sty_id NUMBER,
9282: cp_date DATE) IS
9283: SELECT NVL(SUM (NVL (ste.amount, 0)),0) amount_payable
9284: FROM okl_streams stm,
9285: okl_strm_type_b sty,
9286: okl_strm_elements ste,
9287: okl_pool_contents pocb
9288: WHERE stm.khr_id = cp_contract_id

Line 9367: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

9363: END IF;
9364:
9365: --PAGARG 19-Nov-2004 Bug# 4012614
9366: --UDS impact. Obtain stream type id and pass it to cursor
9367: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
9368: 'PRINCIPAL_PAYMENT',
9369: l_return_status,
9370: l_sty_id);
9371:

Line 9392: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

9388: END IF;
9389:
9390: --PAGARG 19-Nov-2004 Bug# 4012614
9391: --UDS impact. Obtain stream type id and pass it to cursor
9392: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
9393: 'INTEREST_PAYMENT',
9394: l_return_status,
9395: l_sty_id);
9396:

Line 9417: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

9413: END IF;
9414:
9415: --PAGARG 19-Nov-2004 Bug# 4012614
9416: --UDS impact. Obtain stream type id and pass it to cursor
9417: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
9418: 'UNSCHEDULED_PRINCIPAL_PAYMENT',
9419: l_return_status,
9420: l_sty_id);
9421:

Line 9444: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,

9440: --Calculate Total Unbilled Interest Amount
9441: l_unbill_loan_amount := l_unbill_principal_amount+l_unbill_interest_amount+l_unbill_ppd_amount;
9442:
9443: --06-Dec-2004 PAGARG Bug# 3948473 Pass investor agreement id to obtain stream id
9444: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,
9445: 'INVESTOR_PRINCIPAL_DISB_BASIS',
9446: l_return_status,
9447: l_sty_id);
9448:

Line 9467: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,

9463: FETCH l_undisb_rent_stream_csr INTO l_undisb_principal_amount;
9464: CLOSE l_undisb_rent_stream_csr;
9465: END IF;
9466:
9467: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,
9468: 'INVESTOR_INTEREST_DISB_BASIS',
9469: l_return_status,
9470: l_sty_id);
9471:

Line 9490: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,

9486: FETCH l_undisb_rent_stream_csr INTO l_undisb_interest_amount;
9487: CLOSE l_undisb_rent_stream_csr;
9488: END IF;
9489:
9490: OKL_STREAMS_UTIL.get_primary_stream_type(l_inv_agr_id,
9491: 'INVESTOR_PPD_DISB_BASIS',
9492: l_return_status,
9493: l_sty_id);
9494:

Line 9708: FROM okl_streams stm,

9704: cp_chr_id NUMBER,
9705: cp_fee_type VARCHAR2,
9706: cp_date DATE ) IS -- rmunjulu EDAT
9707: SELECT SUM(ste.amount) amount
9708: FROM okl_streams stm,
9709: okl_strm_type_b sty,
9710: okc_k_lines_b kle,
9711: okc_statuses_b kls,
9712: okc_line_styles_b lse,

Line 9740: FROM okl_streams stm

9736: cp_chr_id NUMBER,
9737: cp_fee_type VARCHAR2,
9738: cp_date DATE ) IS -- rmunjulu EDAT
9739: SELECT SUM(ste.amount) amount
9740: FROM okl_streams stm
9741: ,okl_strm_type_b sty
9742: ,okc_k_lines_b kle
9743: ,okc_statuses_b kls
9744: ,okc_line_styles_b lse

Line 9774: FROM okl_streams stm

9770: cp_fee_type VARCHAR2,
9771: cp_asset_id NUMBER,
9772: cp_date DATE ) IS -- rmunjulu EDAT
9773: SELECT SUM(ste.amount) amount
9774: FROM okl_streams stm
9775: ,okl_strm_type_b sty
9776: ,okc_k_lines_b kle
9777: ,okc_statuses_b kls
9778: ,okc_line_styles_b lse

Line 10066: okl_streams stmb,

10062: p_date_terminated okc_k_lines_b.date_terminated%TYPE,
10063: p_sty_id okl_strm_type_b.id%TYPE) IS
10064: SELECT NVL(SUM(selb.amount),0)
10065: FROM
10066: okl_streams stmb,
10067: okl_strm_elements selb
10068: WHERE stmb.id = selb.stm_id
10069: AND stmb.say_code = 'CURR'
10070: AND stmb.active_yn = 'Y'

Line 10097: okl_streams_util.get_dependent_stream_type(

10093:
10094: IF (r_subsidy_line.date_terminated IS NOT NULL) THEN
10095:
10096: /* Bug 6353756 Get dependent stream type from r_subsidy_line.sty_id */
10097: okl_streams_util.get_dependent_stream_type(
10098: p_khr_id => r_subsidy_line.chr_id,
10099: p_primary_sty_id => r_subsidy_line.sty_id,
10100: p_dependent_sty_purpose => 'SUBSIDY_INCOME',
10101: x_return_status => l_return_status,

Line 10186: --okl_streams str, MGAAP 7263041

10182: CURSOR l_line_income_csr (p_chr_id NUMBER) IS
10183: SELECT NVL(str.link_hist_stream_id,-1) link_hist_stream_id,
10184: NVL(SUM(sele.amount),0) amount
10185: FROM okl_strm_elements sele,
10186: --okl_streams str, MGAAP 7263041
10187: okl_streams_rep_v str,
10188: okl_strm_type_v sty,
10189: okc_k_headers_b CHR,
10190: okc_statuses_b sts

Line 10187: okl_streams_rep_v str,

10183: SELECT NVL(str.link_hist_stream_id,-1) link_hist_stream_id,
10184: NVL(SUM(sele.amount),0) amount
10185: FROM okl_strm_elements sele,
10186: --okl_streams str, MGAAP 7263041
10187: okl_streams_rep_v str,
10188: okl_strm_type_v sty,
10189: okc_k_headers_b CHR,
10190: okc_statuses_b sts
10191: WHERE sele.stm_id = str.id

Line 10872: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;

10868: IF (( p_contract_id IS NULL ) OR ( p_contract_line_id IS NULL )) THEN
10869: RAISE Okl_Api.G_EXCEPTION_UNEXPECTED_ERROR;
10870: END IF;
10871:
10872: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;
10873: l_book_type_code := NULL;
10874: IF (l_streams_repo_policy = 'PRIMARY') THEN
10875: l_book_class := 'CORPORATE';
10876: ELSE

Line 11096: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;

11092: IF (( p_contract_id IS NULL ) OR ( p_contract_line_id IS NULL )) THEN
11093: RAISE Okl_Api.G_EXCEPTION_UNEXPECTED_ERROR;
11094: END IF;
11095:
11096: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;
11097: l_book_type_code := NULL;
11098: IF (l_streams_repo_policy = 'PRIMARY') THEN
11099: l_book_class := 'CORPORATE';
11100: ELSE

Line 11714: --FROM okl_streams stm,

11710: cp_contract_line_id NUMBER,
11711: cp_stream_type_id NUMBER,
11712: cp_trx_date DATE) IS
11713: SELECT SUM (NVL (ste.amount, 0)) amount_due
11714: --FROM okl_streams stm,
11715: FROM okl_streams_rep_v stm,
11716: okl_strm_type_b sty,
11717: okl_strm_elements ste
11718: WHERE stm.khr_id = cp_contract_id

Line 11715: FROM okl_streams_rep_v stm,

11711: cp_stream_type_id NUMBER,
11712: cp_trx_date DATE) IS
11713: SELECT SUM (NVL (ste.amount, 0)) amount_due
11714: --FROM okl_streams stm,
11715: FROM okl_streams_rep_v stm,
11716: okl_strm_type_b sty,
11717: okl_strm_elements ste
11718: WHERE stm.khr_id = cp_contract_id
11719: AND stm.kle_id = cp_contract_line_id

Line 11738: FROM okl_streams stm,

11734: cp_contract_line_id NUMBER,
11735: cp_stream_type_id NUMBER,
11736: cp_trx_date DATE) IS
11737: SELECT SUM (NVL (ste.amount, 0)) amount_due
11738: FROM okl_streams stm,
11739: okl_strm_type_b sty, -- Added this table to get the billable_yn flag
11740: okl_strm_elements ste
11741: WHERE stm.khr_id = cp_contract_id
11742: AND stm.kle_id = cp_contract_line_id

Line 11774: FROM okl_streams stm,

11770: cp_contract_line_id NUMBER,
11771: cp_stream_type_id NUMBER,
11772: cp_trx_date DATE) IS
11773: SELECT nvl(ste.amount, 0) amount
11774: FROM okl_streams stm,
11775: okl_strm_type_b sty,
11776: okl_strm_elements ste
11777: WHERE stm.khr_id = cp_contract_id
11778: AND stm.kle_id = cp_contract_line_id

Line 11813: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,

11809: BEGIN
11810: --PAGARG 31-Dec-2004 Bug# 4097591 Start
11811: --UDS impact. Obtain stream type id and pass it to cursor
11812:
11813: OKL_STREAMS_UTIL.get_primary_stream_type(p_contract_id,
11814: 'RENT',
11815: l_return_status,
11816: l_stream_type_id);
11817:

Line 12034: --okl_streams stm, MGAAP 7263041

12030: cp_trx_date DATE,
12031: p_sty_id NUMBER) IS
12032: SELECT NVL(SUM(sel.amount),0)
12033: FROM okl_strm_elements sel,
12034: --okl_streams stm, MGAAP 7263041
12035: okl_streams_rep_v stm,
12036: okl_strm_type_v sty
12037: WHERE sty.id = p_sty_id
12038: AND stm.sty_id = sty.id

Line 12035: okl_streams_rep_v stm,

12031: p_sty_id NUMBER) IS
12032: SELECT NVL(SUM(sel.amount),0)
12033: FROM okl_strm_elements sel,
12034: --okl_streams stm, MGAAP 7263041
12035: okl_streams_rep_v stm,
12036: okl_strm_type_v sty
12037: WHERE sty.id = p_sty_id
12038: AND stm.sty_id = sty.id
12039: AND stm.say_code = 'CURR'

Line 12056: --okl_streams stm, MGAAP 7263041

12052: --Instead of using stream name, join the sty id passed to cursor
12053: CURSOR line_reporting_csr (c_contract_line_id IN NUMBER, cp_trx_date IN DATE, p_sty_id NUMBER) IS
12054: SELECT NVL(SUM(sel.amount),0)
12055: FROM okl_strm_elements sel,
12056: --okl_streams stm, MGAAP 7263041
12057: okl_streams_rep_v stm,
12058: okl_strm_type_v sty
12059: WHERE sty.id = p_sty_id
12060: AND stm.sty_id = sty.id

Line 12057: okl_streams_rep_v stm,

12053: CURSOR line_reporting_csr (c_contract_line_id IN NUMBER, cp_trx_date IN DATE, p_sty_id NUMBER) IS
12054: SELECT NVL(SUM(sel.amount),0)
12055: FROM okl_strm_elements sel,
12056: --okl_streams stm, MGAAP 7263041
12057: okl_streams_rep_v stm,
12058: okl_strm_type_v sty
12059: WHERE sty.id = p_sty_id
12060: AND stm.sty_id = sty.id
12061: AND stm.say_code = 'CURR' -- reporting streams are current

Line 12094: --okl_streams stm, MGAAP 7263041

12090: cp_trx_date DATE,
12091: p_sty_id NUMBER) IS
12092: SELECT NVL(sel.amount,0) amount
12093: FROM okl_strm_elements sel,
12094: --okl_streams stm, MGAAP 7263041
12095: okl_streams_rep_v stm,
12096: okl_strm_type_v sty
12097: WHERE sty.id = p_sty_id
12098: AND stm.sty_id = sty.id

Line 12095: okl_streams_rep_v stm,

12091: p_sty_id NUMBER) IS
12092: SELECT NVL(sel.amount,0) amount
12093: FROM okl_strm_elements sel,
12094: --okl_streams stm, MGAAP 7263041
12095: okl_streams_rep_v stm,
12096: okl_strm_type_v sty
12097: WHERE sty.id = p_sty_id
12098: AND stm.sty_id = sty.id
12099: AND stm.say_code = 'CURR'

Line 12171: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,

12167: x_msg_data => l_msg_data,
12168: p_contract_id => p_contract_id,
12169: x_rep_product_id => lx_rep_product_id);
12170:
12171: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,
12172: p_product_id => lx_rep_product_id,
12173: p_primary_sty_purpose => 'RENT',
12174: p_dependent_sty_purpose => 'LEASE_INCOME',
12175: x_return_status => l_return_status,

Line 12188: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,

12184: ELSE
12185: -- sechawla 05-dec-07 6671849 -- START
12186: --PAGARG 31-Dec-2004 Bug# 4097591 Start
12187: --UDS impact. Obtain stream type id and pass it to cursor
12188: OKL_STREAMS_UTIL.get_dependent_stream_type(p_khr_id => p_contract_id,
12189: p_primary_sty_purpose => 'RENT',
12190: p_dependent_sty_purpose => 'LEASE_INCOME',
12191: x_return_status => l_return_status,
12192: x_dependent_sty_id => l_stream_type_id);

Line 12248: OKL_STREAMS_SEC_PVT.SET_REPO_STREAMS; --MGAAP 7263041

12244: -- gboomina Bug 5215019 - End
12245:
12246: --check if streams required for reporting product
12247: IF l_rep_prod_streams_yn = 'Y' THEN
12248: OKL_STREAMS_SEC_PVT.SET_REPO_STREAMS; --MGAAP 7263041
12249: --PAGARG 31-Dec-2004 Bug# 4097591, Pass stream type id to cursor
12250: --OPEN line_reporting_csr(p_contract_line_id, l_end_date, l_stream_type_id); -- now passing l_end_date 26-Aug-2004 3849355
12251: OPEN line_csr(p_contract_line_id, l_end_date, l_stream_type_id); -- now passing l_end_date 26-Aug-2004 3849355
12252: FETCH line_csr INTO l_unearned_income;

Line 12254: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;

12250: --OPEN line_reporting_csr(p_contract_line_id, l_end_date, l_stream_type_id); -- now passing l_end_date 26-Aug-2004 3849355
12251: OPEN line_csr(p_contract_line_id, l_end_date, l_stream_type_id); -- now passing l_end_date 26-Aug-2004 3849355
12252: FETCH line_csr INTO l_unearned_income;
12253: CLOSE line_csr;
12254: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;
12255: ELSE
12256: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;
12257: -- Start : Bug 6030917 : prasjain
12258: --added for prorating incase of partial unit termination

Line 12256: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;

12252: FETCH line_csr INTO l_unearned_income;
12253: CLOSE line_csr;
12254: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;
12255: ELSE
12256: OKL_STREAMS_SEC_PVT.RESET_REPO_STREAMS;
12257: -- Start : Bug 6030917 : prasjain
12258: --added for prorating incase of partial unit termination
12259:
12260: IF nvl(l_proration_factor,1) = 1 THEN

Line 12497: okl_streams stm

12493: SELECT
12494: sel.amount
12495: FROM
12496: okl_strm_elements sel,
12497: okl_streams stm
12498: WHERE
12499: stm.sty_id = p_sty_id
12500: AND stm.khr_id = p_contract_id
12501: AND stm.kle_id = p_contract_line_id

Line 12538: OKL_STREAMS_UTIL.get_dependent_stream_type(

12534: AND lalevl.rgd_code = 'LALEVL'
12535: AND lalevl.id = laslh.rgp_id
12536: AND laslh.rule_information_category = 'LASLH';
12537:
12538: OKL_STREAMS_UTIL.get_dependent_stream_type(
12539: p_khr_id => p_contract_id,
12540: p_primary_sty_id => l_fee_payment_id,
12541: p_dependent_sty_purpose => 'PRINCIPAL_BALANCE',
12542: x_return_status => l_return_status,

Line 12852: okl_streams stm,

12848:
12849: CURSOR cr_unbilled_streams(c_contract_id IN NUMBER) IS
12850: SELECT NVL(sum(sel.amount),0)
12851: FROM okl_strm_elements sel,
12852: okl_streams stm,
12853: okl_strm_type_b sty
12854: WHERE stm.say_code = 'CURR'
12855: AND stm.active_yn = 'Y'
12856: AND stm.purpose_code is NULL

Line 13340: ,okl_streams str

13336: -- get all unbilled receivables for all ACTIVE assets
13337: CURSOR cle_rents_csr(cp_contract_id okc_k_headers_b.id%TYPE) IS
13338: SELECT NVL(SUM(sele.amount),0)
13339: FROM okl_strm_elements sele
13340: ,okl_streams str
13341: ,okl_strm_type_v sty
13342: ,okc_k_lines_v line
13343: ,okc_statuses_b sts
13344: ,okc_line_styles_b style

Line 13396: --,okl_streams str MGAAP 7263041

13392:
13393: CURSOR c_pre_tax_csr(cp_contract_id okc_k_headers_b.id%TYPE) IS
13394: SELECT NVL(SUM(sele.amount),0)
13395: FROM okl_strm_elements sele
13396: --,okl_streams str MGAAP 7263041
13397: ,okl_streams_rep_v str
13398: ,okl_strm_type_v sty
13399: ,okc_k_lines_b line
13400: ,okc_line_styles_b style

Line 13397: ,okl_streams_rep_v str

13393: CURSOR c_pre_tax_csr(cp_contract_id okc_k_headers_b.id%TYPE) IS
13394: SELECT NVL(SUM(sele.amount),0)
13395: FROM okl_strm_elements sele
13396: --,okl_streams str MGAAP 7263041
13397: ,okl_streams_rep_v str
13398: ,okl_strm_type_v sty
13399: ,okc_k_lines_b line
13400: ,okc_line_styles_b style
13401: ,okc_statuses_b sts

Line 13446: ,okl_streams str

13442: CURSOR cle_rents_csr(cp_contract_id okc_k_headers_b.id%TYPE
13443: ,cp_contract_line_id okc_k_lines_b.id%TYPE) IS
13444: SELECT NVL(SUM(sele.amount),0)
13445: FROM okl_strm_elements sele
13446: ,okl_streams str
13447: ,okl_strm_type_v sty
13448: ,okc_k_lines_v line
13449: -- ,okc_statuses_b sts
13450: ,okc_line_styles_b style

Line 13503: --,okl_streams str MGAAP 7263041

13499: ,p_contract_line_id okc_k_lines_b.id%TYPE DEFAULT OKL_API.G_MISS_NUM) RETURN NUMBER IS
13500: CURSOR c_pre_tax_csr(cp_contract_id okc_k_headers_b.id%TYPE ,cp_contract_line_id okc_k_lines_b.id%TYPE) IS
13501: SELECT NVL(SUM(sele.amount),0)
13502: FROM okl_strm_elements sele
13503: --,okl_streams str MGAAP 7263041
13504: ,okl_streams_rep_v str
13505: ,okl_strm_type_v sty
13506: ,okc_k_lines_b line
13507: ,okc_line_styles_b style

Line 13504: ,okl_streams_rep_v str

13500: CURSOR c_pre_tax_csr(cp_contract_id okc_k_headers_b.id%TYPE ,cp_contract_line_id okc_k_lines_b.id%TYPE) IS
13501: SELECT NVL(SUM(sele.amount),0)
13502: FROM okl_strm_elements sele
13503: --,okl_streams str MGAAP 7263041
13504: ,okl_streams_rep_v str
13505: ,okl_strm_type_v sty
13506: ,okc_k_lines_b line
13507: ,okc_line_styles_b style
13508: -- ,okc_statuses_b sts

Line 13567: okl_streams stm,

13563:
13564: CURSOR cr_next_payment_date(c_contract_id IN NUMBER) IS
13565: SELECT MIN(sel.stream_element_date)
13566: FROM okl_strm_elements sel,
13567: okl_streams stm,
13568: okl_strm_type_v sty
13569: WHERE stm.sty_id = sty.id
13570: AND stm.say_code = 'CURR'
13571: AND stm.active_yn = 'Y'

Line 13583: okl_streams stm,

13579: CURSOR cr_next_payment_amt(c_contract_id IN NUMBER,
13580: c_next_due_date IN DATE) IS
13581: SELECT NVL(sum(sel.amount),0)
13582: FROM okl_strm_elements sel,
13583: okl_streams stm,
13584: okl_strm_type_v sty
13585: WHERE stm.sty_id = sty.id
13586: AND stm.say_code = 'CURR'
13587: AND stm.active_yn = 'Y'

Line 14067: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;

14063: RAISE Okl_Api.G_EXCEPTION_UNEXPECTED_ERROR;
14064: END IF;
14065:
14066: -- 7626121
14067: l_streams_repo_policy := OKL_STREAMS_SEC_PVT.GET_STREAMS_POLICY;
14068: l_book_type_code := NULL;
14069: IF (l_streams_repo_policy = 'PRIMARY') THEN
14070: l_book_class := 'CORPORATE';
14071: ELSE