DBA Data[Home] [Help]

APPS.FII_AR_SALES_CREDITS_C dependencies on RA_CUST_TRX_LINE_SALESREPS_ALL

Line 133: from ra_cust_trx_line_salesreps_all

129: REVENUE_PERCENT_SPLIT,
130: g_fii_user_id, g_fii_user_id,
131: g_fii_login_id,
132: SYSDATE, SYSDATE
133: from ra_cust_trx_line_salesreps_all
134: where cust_trx_line_salesrep_id > g_max_salescredit_pk
135: and customer_trx_line_id is not null
136: and nvl(revenue_percent_split, 0) <> 0;
137:

Line 189: -- Merge the updated Sales Credits into FII_AR_SALES_CREDITS using FII_AR_SALESCREDIT_D_T.SALESCREDIT_PK to join with RA_CUST_TRX_LINE_SALESREPS_ALL

185: fii_util.start_timer;
186: fii_util.put_line('');
187: end if;
188:
189: -- Merge the updated Sales Credits into FII_AR_SALES_CREDITS using FII_AR_SALESCREDIT_D_T.SALESCREDIT_PK to join with RA_CUST_TRX_LINE_SALESREPS_ALL
190: -- (for existing rows, delete them if the new revenue percent is 0 else update them; for new rows, insert them if the revenue percent is non-0)
191:
192: -- For non-0 rows, update existing rows and insert new rows
193: MERGE INTO FII_AR_SALES_CREDITS f

Line 194: USING (SELECT sr.* FROM FII_AR_SALES_CREDITS_D_T del, RA_CUST_TRX_LINE_SALESREPS_ALL sr

190: -- (for existing rows, delete them if the new revenue percent is 0 else update them; for new rows, insert them if the revenue percent is non-0)
191:
192: -- For non-0 rows, update existing rows and insert new rows
193: MERGE INTO FII_AR_SALES_CREDITS f
194: USING (SELECT sr.* FROM FII_AR_SALES_CREDITS_D_T del, RA_CUST_TRX_LINE_SALESREPS_ALL sr
195: WHERE nvl(revenue_percent_split, 0) <> 0
196: AND del.salescredit_pk = sr.cust_trx_line_salesrep_id
197: AND del.dml_type = 'U'
198: AND sr.customer_trx_line_id is not null) stg

Line 236: (select SALESCREDIT_PK from FII_AR_SALES_CREDITS_D_T del, RA_CUST_TRX_LINE_SALESREPS_ALL sr

232:
233: -- For rows updated in AR to have revenue_percent=0, delete them from FII
234: DELETE FROM FII_AR_SALES_CREDITS
235: WHERE SALESCREDIT_PK in
236: (select SALESCREDIT_PK from FII_AR_SALES_CREDITS_D_T del, RA_CUST_TRX_LINE_SALESREPS_ALL sr
237: where nvl(REVENUE_PERCENT_SPLIT, 0) = 0
238: and del.salescredit_pk = sr.cust_trx_line_salesrep_id
239: and del.dml_type = 'U');
240:

Line 414: -- Initial Load from RA_CUST_TRX_LINE_SALESREPS_ALL

410: fii_util.put_line(' ');
411: fii_util.put_line('start of second insert');
412: end if;
413:
414: -- Initial Load from RA_CUST_TRX_LINE_SALESREPS_ALL
415: insert /*+ APPEND PARALLEL(F) */ into fii_ar_sales_CREDITS F (
416: SALESCREDIT_PK, INVOICE_LINE_ID,
417: SALESREP_ID, SALESGROUP_ID,
418: REVENUE_PERCENT_SPLIT,

Line 428: from ra_cust_trx_line_salesreps_all S

424: REVENUE_PERCENT_SPLIT,
425: g_fii_user_id, g_fii_user_id,
426: g_fii_login_id,
427: SYSDATE, SYSDATE
428: from ra_cust_trx_line_salesreps_all S
429: where revenue_percent_split <> 0
430: and customer_trx_line_id is not null;
431:
432: if g_debug_flag = 'Y' then