DBA Data[Home] [Help]

APPS.PSA_FUNDS_CHECKER_PKG dependencies on PSA_BC_ALLOC_GT

Line 9552: CURSOR debug_psa_bc_alloc_gt IS

9548: SELECT event_id, ae_header_id, ae_line_num, entity_id, ledger_id,
9549: period_name
9550: FROM xla_psa_bc_lines_v;
9551:
9552: CURSOR debug_psa_bc_alloc_gt IS
9553: SELECT hierarchy_id, ae_header_id, ae_line_num, event_id,
9554: status_code
9555: FROM psa_bc_alloc_gt;
9556:

Line 9555: FROM psa_bc_alloc_gt;

9551:
9552: CURSOR debug_psa_bc_alloc_gt IS
9553: SELECT hierarchy_id, ae_header_id, ae_line_num, event_id,
9554: status_code
9555: FROM psa_bc_alloc_gt;
9556:
9557: -- Check whether all the events from XLA_EVENTS_GT have come to
9558: -- XLA_AE_LINES_GT.
9559: /* If any event is missed we will treat it as

Line 9749: FROM psa_bc_alloc_gt;

9745: CURSOR c_get_hierarchy_id
9746: IS
9747: SELECT
9748: DISTINCT(hierarchy_id)
9749: FROM psa_bc_alloc_gt;
9750:
9751: -- Check whether for a hierarchy events funds check/reserve is
9752: -- failed/rejected.
9753: CURSOR c_chk_funds_hier(p_hierarchy_id NUMBER,

Line 9763: from psa_bc_alloc_gt

9759: WHERE EXISTS
9760: (SELECT 'X' FROM GL_BC_PACKETS
9761: WHERE (ae_header_id, ae_line_num, event_id)
9762: IN (select ae_header_id, ae_line_num, event_id
9763: from psa_bc_alloc_gt
9764: where hierarchy_id = p_hierarchy_id
9765: and status_code = 'P'
9766: )
9767: AND status_code IN ('F', 'R')

Line 9982: store this information into PSA_BC_ALLOC_GT. Events stored in this table are sampled with

9978: /* First level of validation for allocation attributes is two fold:
9979: 1) We check whether transaction lines are related with allocation attributes or not.
9980: If allocation attributes are NOT used we do the normal processing.
9981: 2) Using allocation attributes we find out the relationship amongst trx lines and
9982: store this information into PSA_BC_ALLOC_GT. Events stored in this table are sampled with
9983: events of XLA_PSA_BC_LINES_V. If any event is missing we disallow the group of related
9984: transaction rows to go in for funds operation. */
9985:
9986: -- Preliminary check for allocation attributes usage.

Line 10037: -- now insert parent and child transactions in psa_bc_alloc_gt

10033: );
10034: LOOP
10035: FETCH c_get_child_trx INTO l_child_trx;
10036: EXIT WHEN c_get_child_trx%NOTFOUND;
10037: -- now insert parent and child transactions in psa_bc_alloc_gt
10038: -- with a initial status of 'U' (Unprocessed)
10039: INSERT INTO psa_bc_alloc_gt (
10040: hierarchy_id,
10041: ae_header_id,

Line 10039: INSERT INTO psa_bc_alloc_gt (

10035: FETCH c_get_child_trx INTO l_child_trx;
10036: EXIT WHEN c_get_child_trx%NOTFOUND;
10037: -- now insert parent and child transactions in psa_bc_alloc_gt
10038: -- with a initial status of 'U' (Unprocessed)
10039: INSERT INTO psa_bc_alloc_gt (
10040: hierarchy_id,
10041: ae_header_id,
10042: ae_line_num,
10043: event_id,

Line 10067: FROM psa_bc_alloc_gt

10063: LOOP
10064: SELECT
10065: COUNT(DISTINCT(event_id))
10066: INTO l_alloc_event_cnt
10067: FROM psa_bc_alloc_gt
10068: WHERE hierarchy_id = h.hierarchy_id;
10069:
10070: -- ======================== FND LOG =============================
10071: psa_utils.debug_other_string(g_state_level, l_full_path, ' l_alloc_event_cnt -> '||l_alloc_event_cnt);

Line 10083: FROM psa_bc_alloc_gt pa1

10079: (
10080: (
10081: SELECT
10082: pa1.event_id
10083: FROM psa_bc_alloc_gt pa1
10084: WHERE pa1.hierarchy_id = h.hierarchy_id
10085: )
10086: MINUS
10087: (

Line 10090: FROM psa_bc_alloc_gt pa2

10086: MINUS
10087: (
10088: SELECT
10089: pa2.event_id
10090: FROM psa_bc_alloc_gt pa2
10091: WHERE pa2.event_id = xv.event_id
10092: AND pa2.status_code = 'F'
10093: )
10094: );

Line 10104: psa_bc_alloc_gt

10100: -- Compare both the counts. if they are equal
10101: -- then the hierarchy events are eligible for funds check
10102: IF (l_alloc_event_cnt = NVL(l_xla_event_cnt, 0)) THEN
10103: UPDATE
10104: psa_bc_alloc_gt
10105: SET status_code = 'P'
10106: WHERE hierarchy_id = h.hierarchy_id;
10107: -- ====== FND LOG ======
10108: psa_utils.debug_other_string(g_state_level, l_full_path, ' BCTRL -> Updated '||sql%rowcount||

Line 10113: psa_bc_alloc_gt

10109: ' rows.');
10110: -- ====== FND LOG ======
10111: ELSE
10112: UPDATE
10113: psa_bc_alloc_gt
10114: SET status_code = 'F'
10115: WHERE hierarchy_id = h.hierarchy_id;
10116: -- ====== FND LOG ======
10117: psa_utils.debug_other_string(g_state_level, l_full_path, ' BCTRL -> Updated '||sql%rowcount||

Line 10238: FROM psa_bc_alloc_gt

10234: (
10235: (l_alloc_used = 'Y' and
10236: xv.event_id IN (
10237: SELECT event_id
10238: FROM psa_bc_alloc_gt
10239: WHERE status_code = 'P')
10240: )
10241: OR
10242: (l_alloc_used = 'N')

Line 10534: FROM psa_bc_alloc_gt

10530: UPDATE xla_ae_headers_gt
10531: SET funds_status_code = 'F'
10532: WHERE event_id IN (
10533: SELECT event_id
10534: FROM psa_bc_alloc_gt
10535: WHERE status_code <> 'P');
10536:
10537: IF(SQL%ROWCOUNT<> 0) THEN
10538: -- ====== FND LOG ======

Line 10548: FROM psa_bc_alloc_gt

10544: UPDATE xla_validation_lines_gt vl
10545: SET vl.funds_status_code = 'F76'
10546: WHERE event_id IN (
10547: SELECT event_id
10548: FROM psa_bc_alloc_gt
10549: WHERE status_code <> 'P');
10550:
10551: IF(SQL%ROWCOUNT<> 0) THEN
10552: -- ====== FND LOG ======

Line 10582: FROM psa_bc_alloc_gt

10578: 'P', 'R')
10579: ,result_code = 'F77'
10580: WHERE (ae_header_id, ae_line_num, event_id)
10581: IN (SELECT ae_header_id, ae_line_num, event_id
10582: FROM psa_bc_alloc_gt
10583: WHERE hierarchy_id = h.hierarchy_id
10584: )
10585: AND status_code NOT IN ('F', 'R')
10586: AND session_id = l_session_id

Line 10678: psa_utils.debug_other_string(g_state_level,l_full_path,'Cleaning up psa_bc_alloc_gt Table');

10674: -- PSA regular tables.
10675:
10676: debug_xla ( 'BUDGETARY_CONTROL_END' );
10677:
10678: psa_utils.debug_other_string(g_state_level,l_full_path,'Cleaning up psa_bc_alloc_gt Table');
10679: DELETE FROM psa_bc_alloc_gt; --For bug 7607496
10680: psa_utils.debug_other_string(g_state_level,l_full_path, ' Deleted Rows -> ' || SQL%ROWCOUNT);
10681:
10682: return TRUE;

Line 10679: DELETE FROM psa_bc_alloc_gt; --For bug 7607496

10675:
10676: debug_xla ( 'BUDGETARY_CONTROL_END' );
10677:
10678: psa_utils.debug_other_string(g_state_level,l_full_path,'Cleaning up psa_bc_alloc_gt Table');
10679: DELETE FROM psa_bc_alloc_gt; --For bug 7607496
10680: psa_utils.debug_other_string(g_state_level,l_full_path, ' Deleted Rows -> ' || SQL%ROWCOUNT);
10681:
10682: return TRUE;
10683:

Line 10764: psa_utils.debug_other_string(g_error_level,l_full_path, ' BCTRL -> PSA_BC_ALLOC_GT DUMP');

10760: -- ====== FND LOG ======
10761: END LOOP;
10762:
10763: -- ====== FND LOG ======
10764: psa_utils.debug_other_string(g_error_level,l_full_path, ' BCTRL -> PSA_BC_ALLOC_GT DUMP');
10765: psa_utils.debug_other_string(g_error_level,l_full_path,' --------------------------------------- ');
10766: -- ====== FND LOG ======
10767: FOR p in debug_psa_bc_alloc_gt
10768: LOOP

Line 10767: FOR p in debug_psa_bc_alloc_gt

10763: -- ====== FND LOG ======
10764: psa_utils.debug_other_string(g_error_level,l_full_path, ' BCTRL -> PSA_BC_ALLOC_GT DUMP');
10765: psa_utils.debug_other_string(g_error_level,l_full_path,' --------------------------------------- ');
10766: -- ====== FND LOG ======
10767: FOR p in debug_psa_bc_alloc_gt
10768: LOOP
10769: -- ====== FND LOG ======
10770: psa_utils.debug_other_string(g_error_level,l_full_path, ' HIERARCHY_ID = '||p.hierarchy_id||' , '||
10771: ' EVENT_ID = '||p.event_id||' , '||