DBA Data[Home] [Help]

APPS.CN_MARK_EVENTS_PKG dependencies on CN_QUOTAS

Line 598: FROM cn_quotas_all q

594: FROM cn_cal_per_int_types_all
595: WHERE cal_period_id = p_period_id
596: AND interval_type_id IN(
597: SELECT DISTINCT q.interval_type_id
598: FROM cn_quotas_all q
599: WHERE q.quota_id IN(
600: SELECT quota_id
601: FROM cn_srp_quota_assigns_all
602: WHERE srp_plan_assign_id IN(

Line 644: FROM cn_quotas_all pe

640: WHERE cpit1.cal_period_id = p_period_id
641: AND cpit1.org_id = p_org_id
642: AND cpit1.interval_type_id =
643: (SELECT interval_type_id
644: FROM cn_quotas_all pe
645: WHERE pe.quota_id = p_quota_id
646: AND (
647: pe.incremental_type = 'N'
648: OR (

Line 1794: -- CASE 1: whenever there IS a change IN the CN_QUOTAS,it marks the

1790: -- Plan Element Has different event Names, all will do the same kind of job
1791: -- except the revent to state and the Event Name.
1792: -- Some cases the event name must be same.
1793:
1794: -- CASE 1: whenever there IS a change IN the CN_QUOTAS,it marks the
1795: -- It marks the all the Salesrep under that quotas.
1796: --
1797: -- CASE 2: whenever there is a change in the start date and the end date
1798: -- of CN_QUOTAS, it marks the specific salesreps in that period

Line 1798: -- of CN_QUOTAS, it marks the specific salesreps in that period

1794: -- CASE 1: whenever there IS a change IN the CN_QUOTAS,it marks the
1795: -- It marks the all the Salesrep under that quotas.
1796: --
1797: -- CASE 2: whenever there is a change in the start date and the end date
1798: -- of CN_QUOTAS, it marks the specific salesreps in that period
1799: -- for that quotas.
1800: -- called from trigger
1801: --
1802: -- Case 3: whenever there is a change in the CN_QUOTA_RULES only on revenue

Line 1868: FROM cn_quotas_all

1864:
1865: CURSOR l_quota_dates_csr IS
1866: SELECT start_date
1867: , end_date
1868: FROM cn_quotas_all
1869: WHERE quota_id = p_object_id;
1870:
1871: --clku
1872: CURSOR l_pe_cursor(l_salesrep_id NUMBER, l_period_id NUMBER, l_quota_id NUMBER) IS

Line 1877: temp_quota_id cn_quotas.quota_id%TYPE;

1873: SELECT quota_id
1874: FROM cn_srp_period_quotas_all
1875: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
1876:
1877: temp_quota_id cn_quotas.quota_id%TYPE;
1878: l_return_status VARCHAR2(50);
1879: l_msg_count NUMBER;
1880: l_msg_data VARCHAR2(2000);
1881: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 2216: FROM cn_quotas_all

2212:
2213: CURSOR l_quota_dates_csr IS
2214: SELECT start_date
2215: , end_date
2216: FROM cn_quotas_all
2217: WHERE quota_id = p_object_id;
2218:
2219: CURSOR l_pe_cursor(l_salesrep_id NUMBER, l_period_id NUMBER, l_quota_id NUMBER) IS
2220: SELECT quota_id

Line 2224: temp_quota_id cn_quotas.quota_id%TYPE;

2220: SELECT quota_id
2221: FROM cn_srp_period_quotas_all
2222: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
2223:
2224: temp_quota_id cn_quotas.quota_id%TYPE;
2225: l_return_status VARCHAR2(50);
2226: l_msg_count NUMBER;
2227: l_msg_data VARCHAR2(2000);
2228: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 2453: FROM cn_quotas_all

2449:
2450: CURSOR l_quota_dates_csr IS
2451: SELECT start_date
2452: , end_date
2453: FROM cn_quotas_all
2454: WHERE quota_id = p_object_id;
2455:
2456: CURSOR l_pe_cursor(l_salesrep_id NUMBER, l_period_id NUMBER, l_quota_id NUMBER) IS
2457: SELECT quota_id

Line 2461: temp_quota_id cn_quotas.quota_id%TYPE;

2457: SELECT quota_id
2458: FROM cn_srp_period_quotas_all
2459: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
2460:
2461: temp_quota_id cn_quotas.quota_id%TYPE;
2462: l_return_status VARCHAR2(50);
2463: l_msg_count NUMBER;
2464: l_msg_data VARCHAR2(2000);
2465: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 3016: FROM cn_quotas_all cq, cn_srp_period_quotas_all spq

3012: -- modified by rjin 11/10/1999 add distinct
3013: SELECT DISTINCT spq.salesrep_id
3014: , spq.period_id
3015: , spq.quota_id
3016: FROM cn_quotas_all cq, cn_srp_period_quotas_all spq
3017: , cn_srp_intel_periods_all intel
3018: WHERE cq.calc_formula_id = p_object_id
3019: AND cq.org_id = p_org_id
3020: AND spq.quota_id = cq.quota_id

Line 3032: temp_quota_id cn_quotas.quota_id%TYPE;

3028: SELECT quota_id
3029: FROM cn_srp_period_quotas_all
3030: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
3031:
3032: temp_quota_id cn_quotas.quota_id%TYPE;
3033: l_return_status VARCHAR2(50);
3034: l_msg_count NUMBER;
3035: l_msg_data VARCHAR2(2000);
3036: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 3187: temp_quota_id cn_quotas.quota_id%TYPE;

3183: SELECT quota_id
3184: FROM cn_srp_period_quotas_all
3185: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
3186:
3187: temp_quota_id cn_quotas.quota_id%TYPE;
3188: l_return_status VARCHAR2(50);
3189: l_msg_count NUMBER;
3190: l_msg_data VARCHAR2(2000);
3191: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 3343: temp_quota_id cn_quotas.quota_id%TYPE;

3339: SELECT quota_id
3340: FROM cn_srp_period_quotas
3341: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
3342:
3343: temp_quota_id cn_quotas.quota_id%TYPE;
3344: l_return_status VARCHAR2(50);
3345: l_msg_count NUMBER;
3346: l_msg_data VARCHAR2(2000);
3347: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 3467: FROM cn_quotas_all q, cn_srp_period_quotas_all spq, cn_srp_intel_periods_all intel

3463: CURSOR affected_srp_period_quotas IS
3464: SELECT DISTINCT spq.salesrep_id
3465: , spq.period_id
3466: , spq.quota_id
3467: FROM cn_quotas_all q, cn_srp_period_quotas_all spq, cn_srp_intel_periods_all intel
3468: WHERE q.interval_type_id = p_interval_type_id
3469: AND q.org_id = p_org_id
3470: AND p_end_date >= q.start_date
3471: AND (q.end_date IS NULL OR p_start_date <= q.end_date)

Line 3485: temp_quota_id cn_quotas.quota_id%TYPE;

3481: SELECT quota_id
3482: FROM cn_srp_period_quotas_all
3483: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
3484:
3485: temp_quota_id cn_quotas.quota_id%TYPE;
3486: l_return_status VARCHAR2(50);
3487: l_msg_count NUMBER;
3488: l_msg_data VARCHAR2(2000);
3489: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 3884: temp_quota_id cn_quotas.quota_id%TYPE;

3880: SELECT quota_id
3881: FROM cn_srp_period_quotas_all
3882: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
3883:
3884: temp_quota_id cn_quotas.quota_id%TYPE;
3885: l_return_status VARCHAR2(50);
3886: l_msg_count NUMBER;
3887: l_msg_data VARCHAR2(2000);
3888: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 4049: temp_quota_id cn_quotas.quota_id%TYPE;

4045: SELECT quota_id
4046: FROM cn_srp_period_quotas_all
4047: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
4048:
4049: temp_quota_id cn_quotas.quota_id%TYPE;
4050: l_return_status VARCHAR2(50);
4051: l_msg_count NUMBER;
4052: l_msg_data VARCHAR2(2000);
4053: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 4211: temp_quota_id cn_quotas.quota_id%TYPE;

4207: SELECT quota_id
4208: FROM cn_srp_period_quotas_all
4209: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
4210:
4211: temp_quota_id cn_quotas.quota_id%TYPE;
4212: l_return_status VARCHAR2(50);
4213: l_msg_count NUMBER;
4214: l_msg_data VARCHAR2(2000);
4215: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 4353: temp_quota_id cn_quotas.quota_id%TYPE;

4349: SELECT quota_id
4350: FROM cn_srp_period_quotas_all
4351: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
4352:
4353: temp_quota_id cn_quotas.quota_id%TYPE;
4354: l_return_status VARCHAR2(50);
4355: l_msg_count NUMBER;
4356: l_msg_data VARCHAR2(2000);
4357: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;

Line 4645: temp_quota_id cn_quotas.quota_id%TYPE;

4641: SELECT quota_id
4642: FROM cn_srp_period_quotas_all
4643: WHERE salesrep_id = l_salesrep_id AND period_id = l_period_id AND quota_id = l_quota_id;
4644:
4645: temp_quota_id cn_quotas.quota_id%TYPE;
4646: l_return_status VARCHAR2(50);
4647: l_msg_count NUMBER;
4648: l_msg_data VARCHAR2(2000);
4649: dependent_pe_tbl cn_calc_sql_exps_pvt.num_tbl_type;