DBA Data[Home] [Help]

APPS.PSP_ENC_CREATE_LINES dependencies on PSP_ENC_LINES

Line 1345: Finally, the procedure creates encumbrance lines in PSP_ENC_LINES.

1341: Element Type ID as input parameters. This procedure determines the different accounts that need to be
1342: charged and the amounts that need to be charged until a particular Date. The logic
1343: used to arrive at the charging instructions is derived from CREATE_DISTRIBUTION_LINES
1344: in Oracle Labor Distribution.
1345: Finally, the procedure creates encumbrance lines in PSP_ENC_LINES.
1346: *************************************************************************/
1347:
1348: /**********************************************************************************
1349: CODING LOGIC

Line 3211: --Instead of calling INSERT_ROW of PSP_ENC_LINES for each CI of an assignment, all the lines are collated into an

3207: l_return_status VARCHAR2(1);
3208: BEGIN
3209: --For Enh. Bug 2259310 : Changed the enc_control_tab from array of records to records of array and hence the change
3210: --in the way each element of record to be accessed.
3211: --Instead of calling INSERT_ROW of PSP_ENC_LINES for each CI of an assignment, all the lines are collated into an
3212: --array for an assignment and inserted using Oracle 8i feature
3213:
3214: /* added to skip creation of lines with zero dollars Bug 1671971:- Subha */
3215: IF l_encumbrance_amount <> 0 THEN

Line 3338: fnd_msg_pub.add_exc_msg('PSP_ENC_LINES','INSERT_INTO_ENC_LINES');

3334: WHEN OTHERS THEN
3335: IF (g_error_message IS NULL) THEN
3336: g_error_message := 'INSERT_INTO_ENC_LINES: ' || SQLERRM;
3337: END IF;
3338: fnd_msg_pub.add_exc_msg('PSP_ENC_LINES','INSERT_INTO_ENC_LINES');
3339: p_return_status := fnd_api.g_ret_sts_unexp_error;
3340: END insert_into_enc_lines;
3341:
3342: --------------------------- INSERT INTO CONTROL TABLES --------------------------------------

Line 3649: Purpose: To insert into psp_enc_lines from Array. This procedure has been introduced to bulk insert

3645: Created By: lveerubh
3646:
3647: Date Created By:08-MAR-2002
3648:
3649: Purpose: To insert into psp_enc_lines from Array. This procedure has been introduced to bulk insert
3650: into psp_enc_lines from the record of collection t_enc_lines_array.
3651: Introduced as part of Enhnacement Enc Redesign : Bug 2259310.
3652: Who When What
3653: lveerubh 08-MAR-2002 Created the procedure

Line 3650: into psp_enc_lines from the record of collection t_enc_lines_array.

3646:
3647: Date Created By:08-MAR-2002
3648:
3649: Purpose: To insert into psp_enc_lines from Array. This procedure has been introduced to bulk insert
3650: into psp_enc_lines from the record of collection t_enc_lines_array.
3651: Introduced as part of Enhnacement Enc Redesign : Bug 2259310.
3652: Who When What
3653: lveerubh 08-MAR-2002 Created the procedure
3654: ********************************************************************************************************************************/

Line 3666: insert into psp_enc_lines

3662: l_last_updated_by NUMBER DEFAULT NVL(FND_GLOBAL.USER_ID, -1);
3663: l_last_update_login NUMBER DEFAULT NVL(FND_GLOBAL.LOGIN_ID, -1);
3664: BEGIN
3665: FORALL i IN 1 .. t_enc_lines_array2.r_enc_element_type_id.COUNT
3666: insert into psp_enc_lines
3667: (
3668: enc_element_type_id,
3669: enc_line_id,
3670: business_group_id,

Line 3726: ,PSP_ENC_LINES_S.NEXTVAL

3722: hierarchy_code
3723: )
3724: values (
3725: t_enc_lines_array2.r_enc_element_type_id(i)
3726: ,PSP_ENC_LINES_S.NEXTVAL
3727: ,p_business_group_id
3728: , t_enc_lines_array2.r_encumbrance_date(i)
3729: , t_enc_lines_array2.r_dr_cr_flag(i)
3730: ,round( t_enc_lines_array2.r_encumbrance_amount(i),g_precision) -- introduced rounding for BUg 2916848 Ilo Ehnc.

Line 3782: DELETE psp_enc_lines

3778: , t_enc_lines_array2.r_orig_expenditure_type(i)
3779: , t_enc_lines_array2.r_hierarchy_code(i)
3780: );
3781:
3782: DELETE psp_enc_lines
3783: WHERE payroll_id = p_payroll_id
3784: AND business_group_id = p_business_group_id
3785: AND set_of_books_id = p_set_of_books_id
3786: AND encumbrance_amount = 0;

Line 6630: FROM psp_enc_lines_history pelh

6626: p_element_type_id NUMBER,
6627: p_enc_begin_date DATE) IS
6628: SELECT COUNT(1),
6629: NVL(MAX(pelh.encumbrance_date),p_enc_begin_date)
6630: FROM psp_enc_lines_history pelh
6631: WHERE pelh.assignment_id = l_assignment_id
6632: AND pelh.enc_element_type_id = p_element_type_id
6633: AND pelh.payroll_id = l_payroll_id;
6634:

Line 6666: FROM psp_enc_lines pel

6662: CURSOR c_max_enc_lines_date (p_assignment_id NUMBER,
6663: p_element_type_id NUMBER,
6664: p_enc_begin_date DATE) IS
6665: SELECT COUNT(1), NVL(MAX(pel.encumbrance_date),p_enc_begin_date)
6666: FROM psp_enc_lines pel
6667: WHERE pel.enc_element_type_id = p_element_type_id
6668: AND pel.assignment_id = p_assignment_id
6669: AND pel.payroll_id = l_payroll_id;
6670:

Line 6778: TYPE enclinesasg_tab IS TABLE OF psp_enc_lines.assignment_id%TYPE INDEX BY BINARY_INTEGER;

6774: asg_array asgid_tab,
6775: term_date_array term_date_tab);
6776: t_assignments t_asg_id_rec;
6777:
6778: TYPE enclinesasg_tab IS TABLE OF psp_enc_lines.assignment_id%TYPE INDEX BY BINARY_INTEGER;
6779: TYPE enclinesele_tab IS TABLE OF psp_enc_lines.enc_element_type_id%TYPE INDEX BY BINARY_INTEGER;
6780: TYPE enclinesdat_tab IS TABLE OF psp_enc_lines.encumbrance_date%TYPE INDEX BY BINARY_INTEGER;
6781: TYPE t_enclines_rec IS RECORD
6782: (asg_array enclinesasg_tab,

Line 6779: TYPE enclinesele_tab IS TABLE OF psp_enc_lines.enc_element_type_id%TYPE INDEX BY BINARY_INTEGER;

6775: term_date_array term_date_tab);
6776: t_assignments t_asg_id_rec;
6777:
6778: TYPE enclinesasg_tab IS TABLE OF psp_enc_lines.assignment_id%TYPE INDEX BY BINARY_INTEGER;
6779: TYPE enclinesele_tab IS TABLE OF psp_enc_lines.enc_element_type_id%TYPE INDEX BY BINARY_INTEGER;
6780: TYPE enclinesdat_tab IS TABLE OF psp_enc_lines.encumbrance_date%TYPE INDEX BY BINARY_INTEGER;
6781: TYPE t_enclines_rec IS RECORD
6782: (asg_array enclinesasg_tab,
6783: ele_array enclinesele_tab,

Line 6780: TYPE enclinesdat_tab IS TABLE OF psp_enc_lines.encumbrance_date%TYPE INDEX BY BINARY_INTEGER;

6776: t_assignments t_asg_id_rec;
6777:
6778: TYPE enclinesasg_tab IS TABLE OF psp_enc_lines.assignment_id%TYPE INDEX BY BINARY_INTEGER;
6779: TYPE enclinesele_tab IS TABLE OF psp_enc_lines.enc_element_type_id%TYPE INDEX BY BINARY_INTEGER;
6780: TYPE enclinesdat_tab IS TABLE OF psp_enc_lines.encumbrance_date%TYPE INDEX BY BINARY_INTEGER;
6781: TYPE t_enclines_rec IS RECORD
6782: (asg_array enclinesasg_tab,
6783: ele_array enclinesele_tab,
6784: dat_array enclinesdat_tab);

Line 7213: UPDATE psp_enc_lines_history pelh

7209: END IF;
7210: hr_utility.trace(fnd_date.date_to_canonical(SYSDATE) || ' Completed verify_changes for l_assignment_id: ' || l_assignment_id || ' payroll_id: ' || l_payroll_id);
7211: ELSE
7212: IF (l_liq_all_count > 0) THEN
7213: UPDATE psp_enc_lines_history pelh
7214: SET change_flag = 'N'
7215: WHERE assignment_id = l_assignment_id
7216: AND payroll_id = l_payroll_id
7217: AND change_flag = 'U'

Line 7230: UPDATE psp_enc_lines_history pelh

7226: WHERE assignment_id = l_assignment_id
7227: AND payroll_id = l_payroll_id
7228: AND change_type = 'ZZ';
7229: ELSE
7230: UPDATE psp_enc_lines_history pelh
7231: SET change_flag = 'N'
7232: WHERE assignment_id = l_assignment_id
7233: AND payroll_id = l_payroll_id
7234: AND change_flag = 'U'

Line 7253: UPDATE psp_enc_lines_history pelh

7249: and ppa.date_earned between ptp.start_date and ptp.end_date
7250: and ptp.payroll_id = ppa.payroll_id),l_enc_begin_date)) );
7251:
7252: hr_utility.trace(fnd_date.date_to_canonical(SYSDATE) || ' Updated lines to be liquidated by regular liquidation');
7253: UPDATE psp_enc_lines_history pelh
7254: SET change_flag = 'U'
7255: WHERE assignment_id = l_assignment_id
7256: AND payroll_id = l_payroll_id
7257: AND change_flag = 'N'

Line 7541: fnd_stats.gather_table_stats('PSP', 'PSP_ENC_LINES');

7537: AND pesl.status_code = 'N'
7538: AND pesl.superceded_line_id IS NOT NULL);
7539:
7540: fnd_stats.gather_table_stats('PSP', 'PSP_ENC_CONTROLS');
7541: fnd_stats.gather_table_stats('PSP', 'PSP_ENC_LINES');
7542: fnd_stats.gather_table_stats('PSP', 'PSP_ENC_SUMMARY_LINES');
7543: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Completed Gather Statistics');
7544:
7545: DELETE FROM psp_enc_controls pec

Line 7548: FROM psp_enc_lines pel

7544:
7545: DELETE FROM psp_enc_controls pec
7546: WHERE pec.payroll_action_id = p_payroll_action_id
7547: AND NOT EXISTS (SELECT 1
7548: FROM psp_enc_lines pel
7549: WHERE pel.enc_control_id = pec.enc_control_id);
7550: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted lines in psp_enc_controls which doesnt have a line in psp_enc_lines');
7551:
7552: UPDATE psp_enc_controls pec

Line 7550: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted lines in psp_enc_controls which doesnt have a line in psp_enc_lines');

7546: WHERE pec.payroll_action_id = p_payroll_action_id
7547: AND NOT EXISTS (SELECT 1
7548: FROM psp_enc_lines pel
7549: WHERE pel.enc_control_id = pec.enc_control_id);
7550: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted lines in psp_enc_controls which doesnt have a line in psp_enc_lines');
7551:
7552: UPDATE psp_enc_controls pec
7553: SET (action_code,
7554: number_of_dr, number_of_cr,

Line 7565: FROM psp_enc_lines pel

7561: SUM(fnd_number.canonical_to_number(DECODE(pel.gl_project_flag, 'G', DECODE(pel.dr_cr_flag, 'D', pel.encumbrance_amount, 0), 0))),
7562: SUM(fnd_number.canonical_to_number(DECODE(pel.gl_project_flag, 'G', DECODE(pel.dr_cr_flag, 'C', pel.encumbrance_amount, 0), 0))),
7563: SUM(fnd_number.canonical_to_number(DECODE(pel.gl_project_flag, 'P', DECODE(pel.dr_cr_flag, 'D', pel.encumbrance_amount, 0), 0))),
7564: SUM(fnd_number.canonical_to_number(DECODE(pel.gl_project_flag, 'P', DECODE(pel.dr_cr_flag, 'C', pel.encumbrance_amount, 0), 0)))
7565: FROM psp_enc_lines pel
7566: WHERE pel.enc_control_id = pec.enc_control_id)
7567: WHERE payroll_action_id = p_payroll_action_id;
7568: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Updated summary columns in psp_enc_controls');
7569:

Line 7795: FROM psp_enc_lines_history pelh

7791: NVL(pelh.attribute10, 'NULL_VALUE'),
7792: NVL(pelh.default_reason_code, 'NULL'),
7793: NVL(pelh.suspense_reason_code, 'NULL'),
7794: hierarchy_code
7795: FROM psp_enc_lines_history pelh
7796: WHERE pelh.change_flag = 'U'
7797: AND payroll_id = p_payroll_id
7798: AND assignment_id = p_assignment_id;
7799:

Line 7802: FROM psp_enc_lines_history

7798: AND assignment_id = p_assignment_id;
7799:
7800: CURSOR modified_summary_lines_cur IS
7801: SELECT DISTINCT enc_summary_line_id
7802: FROM psp_enc_lines_history
7803: WHERE change_flag = 'N'
7804: AND payroll_id = p_payroll_id
7805: AND assignment_id = p_assignment_id;
7806:

Line 7816: UPDATE psp_enc_lines_history

7812: p_payroll_id: ' || p_payroll_id || ' p_assignment_id: ' || p_assignment_id || '
7813: p_business_group_id: ' || p_business_group_id || ' p_set_of_books_id: ' || p_set_of_books_id || '
7814: p_enc_line_type: ' || p_enc_line_type);
7815:
7816: UPDATE psp_enc_lines_history
7817: SET change_flag = 'N'
7818: WHERE assignment_id = p_assignment_id
7819: AND payroll_id = p_payroll_id
7820: AND change_flag = 'U'

Line 7825: UPDATE psp_enc_lines_history pelh

7821: AND status_code = 'A';
7822:
7823: IF (g_dff_grouping_option = 'N') THEN
7824: FORALL recno IN 1 .. t_enc_lines_array.r_time_period_id.COUNT
7825: UPDATE psp_enc_lines_history pelh
7826: SET change_flag='U'
7827: WHERE time_period_id = t_enc_lines_array.r_time_period_id(recno)
7828: AND change_flag = 'N'
7829: AND pelh.encumbrance_date = t_enc_lines_array.r_encumbrance_date(recno)

Line 7847: UPDATE psp_enc_lines_history pelh

7843: AND pelh.assignment_id = p_assignment_id
7844: AND pelh.payroll_id = p_payroll_id;
7845: ELSE
7846: FORALL recno IN 1 .. t_enc_lines_array.r_time_period_id.COUNT
7847: UPDATE psp_enc_lines_history pelh
7848: SET change_flag='U'
7849: WHERE time_period_id = t_enc_lines_array.r_time_period_id(recno)
7850: AND change_flag = 'N'
7851: AND pelh.encumbrance_date = t_enc_lines_array.r_encumbrance_date(recno)

Line 7887: UPDATE psp_enc_lines_history pelh

7883:
7884: hr_utility.trace('l_enc_summary_line_id_tl.COUNT: ' || l_enc_summary_line_id_tl.COUNT);
7885:
7886: FORALL recno IN 1..l_enc_summary_line_id_tl.COUNT
7887: UPDATE psp_enc_lines_history pelh
7888: SET change_flag='N'
7889: WHERE enc_summary_line_id = l_enc_summary_line_id_tl(recno)
7890: AND change_flag='U';
7891:

Line 8227: FROM psp_enc_lines_history pelh

8223: WHERE pesl.assignment_id = p_assignment_id
8224: AND pesl.payroll_id = p_payroll_id
8225: AND pesl.status_code = 'A'
8226: AND pesl.enc_summary_line_id IN (SELECT pelh.enc_summary_line_id
8227: FROM psp_enc_lines_history pelh
8228: WHERE pelh.change_flag = 'N'
8229: AND pelh.assignment_id = p_assignment_id
8230: AND pelh.payroll_id = p_payroll_id);
8231: hr_utility.trace(fnd_date.date_to_canonical(SYSDATE) || ' No of liquidation lines created: ' || SQL%ROWCOUNT);

Line 8279: FROM PSP_ENC_LINES pel,

8275: DECODE(g_dff_grouping_option, 'Y', pel.attribute8, NULL) attribute8,
8276: DECODE(g_dff_grouping_option, 'Y', pel.attribute9, NULL) attribute9,
8277: DECODE(g_dff_grouping_option, 'Y', pel.attribute10, NULL) attribute10,
8278: pa.org_id
8279: FROM PSP_ENC_LINES pel,
8280: PSP_ORGANIZATION_ACCOUNTS pos,
8281: pa_projects_all pa
8282: WHERE pel.ENCUMBRANCE_AMOUNT <> 0
8283: AND pel.assignment_id = p_assignment_id

Line 8405: UPDATE psp_enc_lines pel

8401: hr_utility.trace(fnd_date.date_to_canonical(SYSDATE) || ' No of Summary lines created (t_sum_lines.enc_control_id.COUNT): ' || t_sum_lines.enc_control_id.COUNT);
8402:
8403: IF (g_dff_grouping_option = 'Y') THEN
8404: FORALL recno IN 1..t_sum_lines.enc_summary_line_id.COUNT
8405: UPDATE psp_enc_lines pel
8406: SET enc_summary_line_id = t_sum_lines.enc_summary_line_id(recno)
8407: WHERE payroll_action_id = p_payroll_action_id
8408: AND pel.assignment_id = p_assignment_id
8409: AND pel.payroll_id = p_payroll_id

Line 8435: UPDATE psp_enc_lines pel

8431: AND NVL(pel.attribute9, 'NULL') = NVL(t_sum_lines.attribute9(recno), 'NULL')
8432: AND NVL(pel.attribute10, 'NULL') = NVL(t_sum_lines.attribute10(recno), 'NULL');
8433: ELSE
8434: FORALL recno IN 1..t_sum_lines.enc_summary_line_id.COUNT
8435: UPDATE psp_enc_lines pel
8436: SET enc_summary_line_id = t_sum_lines.enc_summary_line_id(recno)
8437: WHERE payroll_action_id = p_payroll_action_id
8438: AND pel.assignment_id = p_assignment_id
8439: AND pel.payroll_id = p_payroll_id

Line 9496: UPDATE psp_enc_lines_history

9492: FETCH superceded_line_cur BULK COLLECT INTO t_superceded_lines.enc_summary_line_id;
9493: CLOSE superceded_line_cur;
9494:
9495: FORALL recno IN 1..t_superceded_lines.enc_summary_line_id.COUNT
9496: UPDATE psp_enc_lines_history
9497: SET change_flag = 'N'
9498: WHERE enc_summary_line_id = t_superceded_lines.enc_summary_line_id(recno);
9499: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');
9500:

Line 9499: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');

9495: FORALL recno IN 1..t_superceded_lines.enc_summary_line_id.COUNT
9496: UPDATE psp_enc_lines_history
9497: SET change_flag = 'N'
9498: WHERE enc_summary_line_id = t_superceded_lines.enc_summary_line_id(recno);
9499: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');
9500:
9501: DELETE psp_enc_summary_lines
9502: WHERE payroll_action_id = p_payroll_action_id;
9503: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_summary_lines');

Line 9505: DELETE psp_enc_lines

9501: DELETE psp_enc_summary_lines
9502: WHERE payroll_action_id = p_payroll_action_id;
9503: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_summary_lines');
9504:
9505: DELETE psp_enc_lines
9506: WHERE payroll_action_id = p_payroll_action_id;
9507: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');
9508:
9509: DELETE psp_enc_controls

Line 9507: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');

9503: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_summary_lines');
9504:
9505: DELETE psp_enc_lines
9506: WHERE payroll_action_id = p_payroll_action_id;
9507: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');
9508:
9509: DELETE psp_enc_controls
9510: WHERE payroll_action_id = p_payroll_action_id;
9511: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_controls');

Line 9614: UPDATE psp_enc_lines_history

9610: FETCH superceded_line_cur BULK COLLECT INTO t_superceded_lines.enc_summary_line_id;
9611: CLOSE superceded_line_cur;
9612:
9613: FORALL recno IN 1..t_superceded_lines.enc_summary_line_id.COUNT
9614: UPDATE psp_enc_lines_history
9615: SET change_flag = 'N'
9616: WHERE enc_summary_line_id = t_superceded_lines.enc_summary_line_id(recno);
9617: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');
9618:

Line 9617: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');

9613: FORALL recno IN 1..t_superceded_lines.enc_summary_line_id.COUNT
9614: UPDATE psp_enc_lines_history
9615: SET change_flag = 'N'
9616: WHERE enc_summary_line_id = t_superceded_lines.enc_summary_line_id(recno);
9617: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Reverted respective superceded lines in psp_enc_lines_history');
9618:
9619: DELETE psp_enc_summary_lines
9620: WHERE payroll_action_id = p_payroll_action_id
9621: AND assignment_id = l_assignments(recno);

Line 9624: DELETE psp_enc_lines

9620: WHERE payroll_action_id = p_payroll_action_id
9621: AND assignment_id = l_assignments(recno);
9622: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_summary_lines');
9623:
9624: DELETE psp_enc_lines
9625: WHERE payroll_action_id = p_payroll_action_id
9626: AND assignment_id = l_assignments(recno);
9627: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');
9628:

Line 9627: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');

9623:
9624: DELETE psp_enc_lines
9625: WHERE payroll_action_id = p_payroll_action_id
9626: AND assignment_id = l_assignments(recno);
9627: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_lines');
9628:
9629: DELETE psp_enc_controls pec
9630: WHERE payroll_action_id = p_payroll_action_id
9631: AND NOT EXISTS (SELECT 1

Line 9632: FROM psp_enc_lines pel

9628:
9629: DELETE psp_enc_controls pec
9630: WHERE payroll_action_id = p_payroll_action_id
9631: AND NOT EXISTS (SELECT 1
9632: FROM psp_enc_lines pel
9633: WHERE payroll_action_id = p_payroll_action_id
9634: AND pel.enc_control_id = pec.enc_control_id);
9635: fnd_file.put_line(fnd_file.log, fnd_date.date_to_canonical(SYSDATE) || ' Deleted respective lines in psp_enc_controls');
9636:

Line 11254: FROM psp_enc_lines

11250: NVL(expenditure_organization_id, -99),
11251: NVL(expenditure_type, '-99'),
11252: enc_start_date,
11253: enc_end_date
11254: FROM psp_enc_lines
11255: WHERE payroll_action_id = p_payroll_action_id
11256: AND assignment_id = p_assignment_id
11257: AND payroll_id = p_payroll_id
11258: ORDER BY 1, 2, 3, 4, 5, 6, 7, 8, 9, 10;

Line 11271: FROM psp_enc_lines_history

11267: NVL(expenditure_organization_id, -99),
11268: NVL(expenditure_type, '-99'),
11269: enc_start_date,
11270: enc_end_date
11271: FROM psp_enc_lines_history
11272: WHERE assignment_id = p_assignment_id
11273: AND payroll_id = p_payroll_id
11274: AND change_flag = 'N'
11275: ORDER BY 1, 2, 3, 4, 5, 6, 7, 8, 9, 10;

Line 11354: UPDATE psp_enc_lines

11350: END IF;
11351: END LOOP;
11352:
11353: FORALL recno IN 1..t_enc_nlines.element_type_id.COUNT
11354: UPDATE psp_enc_lines
11355: SET hierarchy_start_date = t_enc_nlines.enc_start_date(recno),
11356: hierarchy_end_date = t_enc_nlines.enc_end_date(recno)
11357: WHERE payroll_action_id = p_payroll_action_id
11358: AND assignment_id = p_assignment_id

Line 11369: UPDATE psp_enc_lines

11365: AND enc_start_date <= t_enc_nlines.enc_end_date(recno)
11366: AND enc_end_date >= t_enc_nlines.enc_start_date(recno);
11367:
11368: FORALL recno IN 1..t_enc_nlines.element_type_id.COUNT
11369: UPDATE psp_enc_lines
11370: SET hierarchy_start_date = t_enc_nlines.enc_start_date(recno),
11371: hierarchy_end_date = t_enc_nlines.enc_end_date(recno)
11372: WHERE payroll_action_id = p_payroll_action_id
11373: AND assignment_id = p_assignment_id

Line 11470: UPDATE psp_enc_lines_history

11466: END IF;
11467: END LOOP;
11468:
11469: FORALL recno IN 1..t_enc_nlines.element_type_id.COUNT
11470: UPDATE psp_enc_lines_history
11471: SET hierarchy_start_date = t_enc_nlines.enc_start_date(recno),
11472: hierarchy_end_date = t_enc_nlines.enc_end_date(recno)
11473: WHERE assignment_id = p_assignment_id
11474: AND payroll_id = p_payroll_id

Line 11485: UPDATE psp_enc_lines_history

11481: AND enc_start_date <= t_enc_nlines.enc_end_date(recno)
11482: AND enc_end_date >= t_enc_nlines.enc_start_date(recno);
11483:
11484: FORALL recno IN 1..t_enc_nlines.element_type_id.COUNT
11485: UPDATE psp_enc_lines_history
11486: SET hierarchy_start_date = t_enc_nlines.enc_start_date(recno),
11487: hierarchy_end_date = t_enc_nlines.enc_end_date(recno)
11488: WHERE assignment_id = p_assignment_id
11489: AND payroll_id = p_payroll_id