DBA Data[Home] [Help]

APPS.PSP_PI_IMPORT_DATA dependencies on PSP_PAYROLL_INTERFACE

Line 8: g_bg_currency_code psp_payroll_interface.currency_code%type;

4: This package has been created for concurrent processing. This contains parameters
5: for errbuf and retCode. This has been modified on 05/08/98 by Al Arunachalam
6: **********************************************************************************************/
7: retVal Number;
8: g_bg_currency_code psp_payroll_interface.currency_code%type;
9: g_sob_currency_code gl_sets_of_books.currency_code%type; -- Introduced for bug fix 3107800
10:
11:
12: -- Introduced v_precision,v_ext_precision,v_currency_code in perform_validation for Bug 2916848

Line 79: FROM psp_payroll_interface

75:
76: -- Enh. fix 2094036
77: CURSOR payroll_interface_check_cur IS
78: SELECT payroll_interface_id
79: FROM psp_payroll_interface
80: WHERE batch_name = v_batch_name
81: AND business_group_id = v_business_group_id
82: AND set_of_books_id = v_set_of_books_id
83: FOR UPDATE OF payroll_interface_id NOWAIT;

Line 98: l_currency_code psp_payroll_interface.currency_code%type;

94: FROM gl_sets_of_books gsob
95: WHERE set_of_books_id = v_set_of_books_id;
96: -- End of fix 3107800
97:
98: l_currency_code psp_payroll_interface.currency_code%type;
99:
100: l_precision NUMBER;
101: l_ext_precision NUMBER;
102:

Line 239: from PSP_PAYROLL_INTERFACE

235: *****************************************************************************************/
236: Function Change_To_Transfer(v_Batch_Name IN varchar2) return Number IS
237: Cursor Change_Statuses Is
238: select STATUS_CODE
239: from PSP_PAYROLL_INTERFACE
240: where Batch_Name = v_Batch_Name
241: FOR UPDATE OF STATUS_CODE;
242: Change_Statuses_Agg Change_Statuses%RowType;
243: Begin

Line 245: Update PSP_PAYROLL_INTERFACE set STATUS_CODE = 'T' where CURRENT OF Change_Statuses;

241: FOR UPDATE OF STATUS_CODE;
242: Change_Statuses_Agg Change_Statuses%RowType;
243: Begin
244: FOR Change_Statuses_Agg IN Change_Statuses LOOP
245: Update PSP_PAYROLL_INTERFACE set STATUS_CODE = 'T' where CURRENT OF Change_Statuses;
246: End Loop;
247: return 0;
248: Exception
249: when others then

Line 275: from PSP_PAYROLL_INTERFACE

271: v_precision,v_ext_precision,v_currency_code);
272: -- Next, check if any records have statuses other than Valid
273: select count(*)
274: into n_Valid_Records
275: from PSP_PAYROLL_INTERFACE
276: where Batch_Name = v_Batch_Name
277: and STATUS_CODE <> 'V';
278: -- If records do not have Valid status, then inform the user
279: -- and exit. Else, continue

Line 295: is where data from PSP_PAYROLL_INTERFACE is imported to PSP_PAYROLL_CONTROLS. After

291: End If;
292: End Perform_Validations;
293: /*******************************Perform_Import*******************************************
294: OBJ: This is a private procedure (called internally, from Import_Records). This
295: is where data from PSP_PAYROLL_INTERFACE is imported to PSP_PAYROLL_CONTROLS. After
296: this has been done successfully, the Import_Payroll_Lines procedure is called.
297: CREATED BY: AL ARUNACHALAM
298: DATE: 03/27/98
299:

Line 308: From PSP_PAYROLL_INTERFACE

304: v_ext_precision IN NUMBER,v_currency_code IN VARCHAR2) return Number IS
305: cursor Control_Record IS
306: Select DISTINCT Payroll_Period_ID, Payroll_Source_Code,
307: GL_POSTING_OVERRIDE_DATE,GMS_POSTING_OVERRIDE_DATE
308: From PSP_PAYROLL_INTERFACE
309: Where Batch_Name = v_Batch_Name
310: And STATUS_CODE <> 'T';
311: n_Payroll_ID Number;
312:

Line 357: From PSP_PAYROLL_INTERFACE

353: -- Obtain the Payroll ID for every Payroll Period being added to the table
354: Begin
355: Select DISTINCT Payroll_ID
356: Into n_Payroll_ID
357: From PSP_PAYROLL_INTERFACE
358: where PAYROLL_PERIOD_ID = Control_Record_Agg.Payroll_Period_ID
359: and PAYROLL_SOURCE_CODE = Control_Record_Agg.Payroll_Source_Code
360: and BATCH_NAME = v_Batch_Name;
361: Exception

Line 398: from PSP_PAYROLL_INTERFACE

394: -- Next, obtain the Number of Credits, Debits, Credit Amount, and Debit amount
395: -- for every record being added
396: select Count(DR_CR_FLAG), SUM(ROUND(PAY_AMOUNT,v_precision))
397: into n_Number_Of_Credits, n_Credit_Amount
398: from PSP_PAYROLL_INTERFACE
399: where Payroll_Period_ID = Control_Record_Agg.Payroll_Period_ID
400: and Payroll_Source_Code = Control_Record_Agg.Payroll_Source_Code
401: and Batch_Name = v_Batch_Name
402: and UPPER(DR_CR_FLAG) = 'C';

Line 406: from PSP_PAYROLL_INTERFACE

402: and UPPER(DR_CR_FLAG) = 'C';
403:
404: select Count(DR_CR_FLAG), SUM(ROUND(PAY_AMOUNT,v_precision))
405: into n_Number_Of_Debits, n_Debit_Amount
406: from PSP_PAYROLL_INTERFACE
407: where Payroll_Period_ID = Control_Record_Agg.Payroll_Period_ID
408: and Payroll_Source_Code = Control_Record_Agg.Payroll_Source_Code
409: and Batch_Name = v_Batch_Name
410: and UPPER(DR_CR_FLAG) = 'D';

Line 415: from PSP_PAYROLL_INTERFACE

411:
412: -- Also, obtain the Total Sublines CR Amount and Total Sublines DR Amount for Batch
413: Select SUM(ROUND(PAY_AMOUNT,v_precision))
414: into v_Sublines_CR_Amount
415: from PSP_PAYROLL_INTERFACE
416: where Batch_Name = v_Batch_Name
417: -- Introduced Time Period and Source Code check for bug fix 3116383
418: AND payroll_period_id = control_record_agg.payroll_period_id
419: AND payroll_source_code = control_record_agg.payroll_source_code

Line 424: from PSP_PAYROLL_INTERFACE

420: and UPPER(DR_CR_FLAG) = 'C';
421:
422: Select SUM(ROUND(PAY_AMOUNT,v_precision))
423: into v_Sublines_DR_Amount
424: from PSP_PAYROLL_INTERFACE
425: where Batch_Name = v_Batch_Name
426: -- Introduced Time Period and Source Code check for bug fix 3116383
427: AND payroll_period_id = control_record_agg.payroll_period_id
428: AND payroll_source_code = control_record_agg.payroll_source_code

Line 514: From PSP_PAYROLL_INTERFACE

510: v_precision IN NUMBER,v_ext_precision IN NUMBER) return Number IS
511: cursor Lines_Record IS
512: Select DISTINCT Payroll_Period_ID, Assignment_ID, Element_Type_ID, Payroll_Source_Code,
513: Sub_Line_Start_Date, Sub_Line_End_Date
514: From PSP_PAYROLL_INTERFACE
515: Where Batch_Name = v_Batch_Name
516: And STATUS_CODE <> 'T';
517: Lines_Record_Agg Lines_Record%ROWTYPE;
518: v_ROWID varchar2(30);

Line 565: From PSP_PAYROLL_INTERFACE

561: -- Obtain Payroll ID for a given Payroll Period and the non-oracle source code
562: BEGIN
563: Select DISTINCT Payroll_ID
564: Into n_Payroll_ID
565: From PSP_PAYROLL_INTERFACE
566: where PAYROLL_PERIOD_ID = Lines_Record_Agg.Payroll_Period_ID
567: and PAYROLL_SOURCE_CODE = Lines_Record_Agg.Payroll_Source_Code
568: and BATCH_NAME = v_Batch_Name;
569: -- dbms_output.put_line('Payroll ID ' || to_Char(n_Payroll_ID) || ' obtained');

Line 580: -- Obtain information from PSP_PAYROLL_INTERFACE table that is to be inserted into the

576: return 1;
577: END;
578:
579: */
580: -- Obtain information from PSP_PAYROLL_INTERFACE table that is to be inserted into the
581: -- PSP_PAYROLL_LINES table
582: -- n_payroll_id Added for bug fix 4179476
583: BEGIN
584: Select DISTINCT Effective_Date, Person_ID, round(Pay_Amount,v_precision),

Line 588: From PSP_PAYROLL_INTERFACE

584: Select DISTINCT Effective_Date, Person_ID, round(Pay_Amount,v_precision),
585: Check_Date, Earned_Date, UPPER(DR_CR_Flag), payroll_id
586: Into d_Effective_Date, n_Person_ID, n_Pay_Amount, d_Check_Date, d_Earned_Date,
587: v_DR_CR_Flag, n_payroll_id
588: From PSP_PAYROLL_INTERFACE
589: where PAYROLL_PERIOD_ID = Lines_Record_Agg.Payroll_Period_ID
590: and PAYROLL_SOURCE_CODE = Lines_Record_Agg.Payroll_Source_Code
591: --Condition Droped for bug fix 4179476
592: -- and PAYROLL_ID = n_Payroll_ID

Line 708: -- PSP_Payroll_Interface table

704: X_MODE => 'R'
705: );
706: -- Finally, create Payroll Sub line records in PSP_Payroll_Sub_Lines table
707: -- Create a record in PSP_payroll_sub_lines table for every record in
708: -- PSP_Payroll_Interface table
709: -- dbms_output.put_line('Inserted into Payroll Lines. Now, inserting to Payroll Sub
710: -- lines');
711: retVal := Process_Payroll_Sub_Lines(v_batch_name, Lines_Record_Agg.Payroll_Period_ID,
712: Lines_Record_Agg.Assignment_ID, Lines_Record_Agg.Element_Type_ID,

Line 747: From PSP_PAYROLL_INTERFACE

743: v_business_group_id IN NUMBER) -- Introduced BG for bug 2908859
744: return Number IS
745: cursor Sub_Lines_Record IS
746: Select *
747: From PSP_PAYROLL_INTERFACE
748: where Batch_Name = v_batch_name
749: and PAYROLL_PERIOD_ID = n_Payroll_Period_ID
750: and ASSIGNMENT_ID = n_Assignment_ID
751: and ELEMENT_TYPE_ID = n_Element_Type_ID

Line 913: -- Check if any invalid batch names exist in PSP_PAYROLL_INTERFACE

909:
910: FUNCTION Check_For_Valid_Batches(v_Batch_Name IN VARCHAR2,
911: v_business_group_id IN NUMBER,
912: v_set_of_books_id IN NUMBER ) return NUMBER IS
913: -- Check if any invalid batch names exist in PSP_PAYROLL_INTERFACE
914: -- i.e. check if any non-transferred batch exists in PSP_PAYROLL_INTERFACE
915: -- that already exists in PSP_PAYROLL_CONTROLS.
916: -- If it does, then inform the user about the error and exit.
917: cursor C1 is

Line 914: -- i.e. check if any non-transferred batch exists in PSP_PAYROLL_INTERFACE

910: FUNCTION Check_For_Valid_Batches(v_Batch_Name IN VARCHAR2,
911: v_business_group_id IN NUMBER,
912: v_set_of_books_id IN NUMBER ) return NUMBER IS
913: -- Check if any invalid batch names exist in PSP_PAYROLL_INTERFACE
914: -- i.e. check if any non-transferred batch exists in PSP_PAYROLL_INTERFACE
915: -- that already exists in PSP_PAYROLL_CONTROLS.
916: -- If it does, then inform the user about the error and exit.
917: cursor C1 is
918: /***** Modified the following cursor defn for R12 performance fixes (bug 4507892)

Line 920: from PSP_PAYROLL_INTERFACE a,

916: -- If it does, then inform the user about the error and exit.
917: cursor C1 is
918: /***** Modified the following cursor defn for R12 performance fixes (bug 4507892)
919: Select DISTINCT a.batch_name batch_name
920: from PSP_PAYROLL_INTERFACE a,
921: PSP_PAYROLL_CONTROLS b
922: where a.batch_name = b.batch_name
923: and a.status_code <> 'T'
924: and b.SOURCE_TYPE = 'N'

Line 931: FROM psp_payroll_interface ppi

927: and b.set_of_books_id = v_set_of_books_id;
928: End of comment for bug fix 4507892 *****/
929: -- New cursor defn for bug fix 4507892
930: SELECT ppi.batch_name batch_name
931: FROM psp_payroll_interface ppi
932: WHERE ppi.batch_name = v_batch_name
933: AND ppi.business_group_id = v_business_group_id
934: AND ppi.set_of_books_id = v_set_of_books_id
935: AND ppi.status_code <> 'T'

Line 943: C1_Batch_Name PSP_PAYROLL_INTERFACE.batch_name%TYPE;

939: AND ppc.SOURCE_TYPE = 'N'
940: AND ppc.business_group_id = v_business_group_id
941: AND ppc.set_of_books_id = v_set_of_books_id);
942:
943: C1_Batch_Name PSP_PAYROLL_INTERFACE.batch_name%TYPE;
944: BEGIN
945: Open C1;
946: LOOP
947: Fetch C1 INTO C1_Batch_Name;

Line 976: FROM PSP_PAYROLL_INTERFACE

972:
973:
974: CURSOR Count_currency_code_cur IS
975: SELECT COUNT(DISTINCT(NVL(currency_code,'*')))
976: FROM PSP_PAYROLL_INTERFACE
977: WHERE batch_name = v_batch_name
978: AND business_group_id = v_business_group_id
979: AND set_of_books_id = v_set_of_books_id;
980:

Line 1015: FROM PSP_PAYROLL_INTERFACE

1011:
1012:
1013: CURSOR get_currency_code_cur IS
1014: SELECT DISTINCT(NVL(currency_code,g_bg_currency_code))
1015: FROM PSP_PAYROLL_INTERFACE
1016: WHERE batch_name = v_batch_name
1017: AND business_group_id = v_business_group_id
1018: AND set_of_books_id = v_set_of_books_id
1019: AND rownum = 1;

Line 1021: l_currency_code psp_payroll_interface.currency_code%type;

1017: AND business_group_id = v_business_group_id
1018: AND set_of_books_id = v_set_of_books_id
1019: AND rownum = 1;
1020:
1021: l_currency_code psp_payroll_interface.currency_code%type;
1022:
1023:
1024: BEGIN
1025: