Search This Blog

Monday, April 6, 2015

API Creating Assignment sets and Inserting records into Assignment sets

Creating Assignment set:

 There is no api to create assignment sets, we need to insert as below.

1.
insert into HR_ASSIGNMENT_SETS
( ASSIGNMENT_SET_ID,
BUSINESS_GROUP_ID,
PAYROLL_ID,
ASSIGNMENT_SET_NAME,
FORMULA_ID)
values
(HR_ASSIGNMENT_SETS_S.nextval,
81,
106,
'DIEJUL20143',
NULL
)

2.Inserting row into assignment set using api...

HR_ASSIGNMENT_SET_AMDS_PKG.insert_row
(
p_rowid in out varchar2,
p_assignment_id in number,
p_assignment_set_id in number,
p_include_or_exclude in varchar2);

Example:

DECLARE
p_rowid varchar2(20);-- := null;
BEGIN
HR_ASSIGNMENT_SET_AMDS_PKG.insert_row
(
p_rowid=> p_rowid,
p_assignment_id => 7687,
p_assignment_set_id =>96118,
p_include_or_exclude =>'I');
END;


Other Queries:

SELECT * FROM HR_ASSIGNMENT_SETS
WHERE ASSIGNMENT_SET_NAME = 'DIEJUL20143'

SELECT * FROM HR_ASSIGNMENT_SET_AMENDMENTS
WHERE ASSIGNMENT_SET_ID = 96118

 select HR_ASSIGNMENT_SETS_S.nextval  from dual

1 comment: