Updating people group segments
Hi,
I'm very new to PL/SQL and want to run a sql script to update people group segments based on grade step and ceiling points
I've searched around on metalink and have the beginnings of something but maybe I need to use an extra cursor at the beginning or something? Could anyone help?
Thanks
declare l_people_group_id NUMBER;
select paf.assignment_id, paf.object_version_number, paf.special_ceiling_step_id
into p_assignment_id, l_out_object_version_number, l_special_ceiling_step_id
from per_assignments_f paf,
pay_people_groups ppg
where p_person_id = paf.person_id
and paf.people_group_id = ppg.people_group_id
and p_effective_date between paf.effective_start_date and paf.effective_end_date;
cursor get_current_ceiling_assignment is
select asg.*, ast.per_system_status
from per_assignment_status_types ast,
per_assignments_f asg,
per_grade_spines_f pgsf,
per_spinal_point_steps_f pspsf
where assignment_id = p_assignment_id
and ast.assignment_status_type_id = asg.assignment_status_type_id
and pgsf.grade_spine_id = pspsf.grade_spine_id
and pspsf.step_id = pgsf.ceiling_step_id
and asg.grade_id = pgsf.grade_id
-- and p_effective_date between effective_start_date and effective_end_date;
and asg.effective_start_date = (select max(effective_start_date)
from per_all_assignments_f
where assignment_id = asg.assignment_id);
begin
for v1 in get_current_ceiling_assignment loop
l_out_object_version_number := v1.object_version_number;
l_special_ceiling_step_id := v1.special_ceiling_step_id;
l_datetrack_update_mode := 'UPDATE';
hr_assignment_api.update_emp_asg_criteria
p_validate => false,
p_effective_date => p_effective_date,
p_datetrack_update_mode => l_datetrack_update_mode,
p_assignment_id => p_assignment_id,
p_object_version_number => l_out_object_version_number,
p_special_ceiling_step_id => l_special_ceiling_step_id,
p_segment5 => NULL,
p_segment6 => NULL,
p_group_name => l_group_name,
p_effective_start_date => l_out_effective_start_date,
p_effective_end_date => l_out_effective_end_date,
p_people_group_id => l_people_group_id,
p_org_now_no_manager_warning => l_org_now_no_manager_warning,
p_other_manager_warning => l_other_manager_warning,
p_spp_delete_warning => l_spp_delete_warning,
p_entries_changed_warning => l_entries_changed_warning,
p_tax_district_changed_warning => l_tax_district_changed_warning
end loop;
end;
I'm trying to update two people segments when the grade step reaches the ceiling point.
I'm not expecting anything to be returned in the query but want the api to update the relevant assignment records.
I'm using 11.5.10 apps, 10g database. I just think I'm missing something fundamental with the constrcution of my script here
Similar Messages
-
How to update People Group KFF Segments in Assignment Form
Hi Gurus,
Please help me on how to update people group KFF individual segments on assignment form.
Please provide sample code/reference.
Thanks,
Raghava.Hi Vignesh,
I have tried the api using below code. But im getting the error like below:
ORA-20001: FLEX-VALUE DOES NOT EXIST: N, VALUE, Teachers, N, SEGMENT, PENSION_SCHEME_ESCH, N, VALUESET, GEN_PENS_SCHEME_LOOKUP
ORA-06512: at "APPS.HR_ASSIGNMENT_API", line 16616
ORA-06512: at line 22
Code:
DECLARE
l_people_group_id number;
l_special_ceiling_step_id number;
l_ovn number;
l_soft_coding_keyflex_id number;
l_group_name varchar2(9000);
l_effective_start_date date;
l_effective_end_date date;
l_org_now_no_manager_warning boolean;
l_other_manager_warning boolean;
l_spp_delete_warning boolean;
l_entries_changed_warning varchar2(9000);
l_tax_district_changed_warning boolean;
l_concatenated_segments varchar2(9000);
l_gsp_post_process_warning varchar2(9000);
BEGIN
l_ovn:=11;
--l_people_group_id:=966;
l_soft_coding_keyflex_id:=null;
l_special_ceiling_step_id:=null;
hr_assignment_api.update_emp_asg_criteria
(p_effective_date =>TO_DATE('08-SEP-2012')
,p_datetrack_update_mode =>'CORRECTION'
,p_validate =>FALSE
,p_assignment_id =>37325
--,p_segment1 =>'Local Government Conditions (Green book)'
--,p_segment2 =>'R'
,p_segment3 =>'None'
,p_object_version_number =>l_ovn
,p_special_ceiling_step_id =>l_special_ceiling_step_id
,p_people_group_id =>l_people_group_id
,p_soft_coding_keyflex_id =>l_soft_coding_keyflex_id
,p_group_name =>l_group_name
,p_effective_start_date =>l_effective_start_date
,p_effective_end_date =>l_effective_end_date
,p_org_now_no_manager_warning =>l_org_now_no_manager_warning
,p_other_manager_warning =>l_other_manager_warning
,p_spp_delete_warning =>l_spp_delete_warning
,p_entries_changed_warning =>l_entries_changed_warning
,p_tax_district_changed_warning =>l_tax_district_changed_warning
,p_concatenated_segments =>l_concatenated_segments
,p_gsp_post_process_warning =>l_gsp_post_process_warning
END;
Commit;
Please help me on how to update the individual segment.
Thanks
Raghava -
How to set Default Value in People Group KFF
Hi
We are storing some information in People Group KFF which depends on Employee Category so if employee category is Permanent Headcount then the value in People group KFF will be different and if it is Temporary then the value will be different.
Now we want to default the People Group KFF value automatically based on Employee Category for a New Hire employee. And also we should be able to change the People Group KFF value for some new hire as there are few exceptions.
I tried WHEN-NEW-RECORD-INSTANCE and tried to set the value through INITIAL_VALUE but it is not working.
Kindly please advise if you have idea on how to implement this requirement.
Thanks
GauravHello Gaurav,
If I understood correctly, Your requirement is to update People Group segments based on employee category.
Basically you need to update people group values based on employee category before insert into assignment table.
You can acheive this using Dynamic Trigger on Assignment Table.
you need to change the new.people_group_id along with other segment values in this trigger logic.
Following articles will help you steps on how to create dyanamic triggers.
http://oracle.anilpassi.com/dynamic-triggers-in-hrms-payroll-demo.html
http://apps2fusion.com/apps/oracle-hrms/oracle-hr/204-triggers-in-oracle-hrms-and-payroll
Regards,
Saurabh -
How to populate data in PAY_PEOPLE_GROUPS table (People Group Flexfiled)
Hello
We are migrating the data from one oracle instance to another oracle instance which are in same version of Oralce Applications 11.5.10.2. As a part of migration can anybody let me know how to populate data in "People Group Key Flexfiled" (PAY_PEOPLE_GROUPS table), ideally I will create or update employee records from the source instance to destination instance, so while creating or updating the employee records in can pass people_group_id while calling to the assignment api but my question here is before passing group id to the api i should have the data populated in PAY_PEOPLE_GROUPS TABLE so that i can fetch the group id as per the combination and pass it in to the api.. please suggest...Thanks for your information! by any chance do you have any sample code which will create/update assignments with People Group Flexfield; when i check "hr_assignment_api.update_emp_asg_criteria" it only has parameter to pass people group id and not having segments parameters to pass individual segments.
Also let me know the links if you have any for all HR API guide which will help me to develope the interfaces...
My requirement is we have two instances in which in one instance we are treating as source for HR which will be used to master for all HR related activities and we are planning to develope an interface which will bring master instance in sync with dummy instance. -
Validation on People Group Key Flexfield
Hi all,
I have a People Group Key flexfield (KFF) defined with 7 Segments, and I want to make 1 of the Segments (SEGMENT7) Read-Only for a specific set of Responsibilities.
I have tried creating a Form Personalization for this, but I don't believe you can achieve this using forms personalizations (because you can only reference the entire flexfield as a whole, and not individual segments).
I have also tried using the Custom Library, and referencing FND_KEY_FLEX.UPDATE_DEFINITION to apply this validation, but I have not been able to get this to work either.
Finally, I have tried creating a security group and attaching it to the Value Set / KFF Segment but this doesn't quite give me what I need, as this only lets you Include/Exclude specific values and not make the segment Read-Only.
Does anyone know how to apply this validation to a People Group KFF Segment?
Thanks in advance,
JonIf nothing else works , you can write a before-update d/b trigger on the underlying table that compares :old.segment7 with :new.segment7 and raises failure if the values differ for the user's logged in responsibility.
-
BAPI_ACC_INVOICE_RECEIPT_POST - Updating Customer Group
Does anyone know how i can update 'Customer Group' in the profit segment part of a document using the above BAPI.
Can it be done ?
Thankshi
I'm searching a BAPI for F-53.
then i found your thread.
but i don't know what data to be filled in it.
can u please provide me some sample data that needs to be filled in this bapi.
awaiting your reply.
Regards,
Suman. -
InfoPath - Populating People/Group field works on Create, but not on Edit
Hi- I have a scenario where there are a few data connections hooked up to a primary form. One of those data connections is connected to an assignment list. It consists of 3 columns (Warehouse(Text), Primary
User(People/Group), Secondary User(People/Group). This list is meant to be a dynamic source that my main form uses to determine assignments. I have a button that pulls in the data from that list onto my form. I am assigning the DisplayName to my DisplayName,
the Account ID to my AccountID and the AccountType to My AccountType. This works just fine when I go to create an item--> all values populate correctly, I can save my form with all of the newly brought in values.
For some reason, every time I open the form after that and try to use the same button, the query runs as normal, but my people/group fields do not populate - assuming they are not already populated. I
have validated that the rules are running and they are running with the values I want (I have written the values from the people/group fields to text fields and they appear to be correct).
I did look at the SP logs and it gave me this: Failed to get SPGroupName from GroupID. Error Message: Group cannot be found. Callstack: at Microsoft.SharePoint.SPGroupCollection.GetByID(Int32 id) at Microsoft.SharePoint.WebControls.PeopleEditor.set_SharePointGroupID(Int32
value).The StateManager is disposing and calling ReleaseLockedStates() (Count=0).
Any thoughts? I have not gotten any errors when interacting with the form. I had to pull this from the ULS logs.
Thanks, Jesse
Jesse A. BrandenburgThe rules go as following:
1) Switch Views to a more specific view (less fields showing)
2) Query Data Connection for assignments
3-12) Set primary contacts
This looks at my assignment list and based on the location sets the display name, account id and account type on
my form, based on what exists on the other list
*I have the same thing happening for 10 fields based on location. I am using a filter for each one to identify the correct location populates that person field.
13) I am setting a field to true that identifies that the rule was just run with a sign and date of username.
I have verified that the values are trying to be populated by looking at bothe the default values of the display name, account id, and account type of my people picker fields, however they are not showing anything within the picker itself. Additionally
I have a view that shows my assignments data connection that is populated correctly.
Thanks for your response -
Jesse
Jesse A. Brandenburg -
Employee Transfer from One People group to another.
Hi All
Suppose a new employee was hired on 01-Jan-2006 and upto 31-May-2007 he was in People Group X. From 01-Jun-2007 he was shifted to[i] People Group Y.
When I query the assignments using Fastpath,
People window etc. all these are correct. But on the People Form it's showing the Effective From Date as 20-Jul-2007 and Latest Start Date as 01-Jan-2006.
Suppose my user has done something due to which I am getting this. What he may have done? And the employee was not terminated.
Any Idea?
Regards
Rahman
Message was edited by:
Md. Abdur RahmanHi Bala
Yes I am talking about the dates on the people screen. Why there are different dates on the People Screen. In the Assignment window everything is fine and also in the View>Worker Assignment window everything is OK.
I have used the Menu Tool>Date Track History also but there are no changes made.
Then why are the dates different in the People Window?
Regards,
Rahman -
Update purchasing group in scheduling agreements
Hi gurus,
I'm trying to update purchasing group field in scheduling agreements, which are time-independent (EKKO-STAKO = ' ').
In my environment, I'm not authorized to use CALL TRANSACTION statement.
If possible, I'd need a way that works both in 4.6c and 6.0 versions.
I have tried several options, but none works:
-BAPI_SAG_CHANGE: "Scheduling agreements with time-independent conditions are not supported" (OSS note 1046794) (Also, this is not available in 4.6c)
-BAPI_SCHEDULE_MAINTAIN: "Scheduling agreements with time-independent conditions are not supported" (OSS note 1046794) (Also, this is not available in 4.6c)
-BAPI_AGREEMENT_MAINTAIN: Does not have the possibility to change field 'purchasing group'. (Moreover, it internally performs a CALL TRANSACTION).
-ME_UPDATE_AGREEMENT_PO: I've been not able to change field 'purchasing group'.
I'd be grateful about any hint. Thanks in advance!In case it is useful for anyone else, I have solved the problem using:
CALL FUNCTION 'ME_UPDATE_DOCUMENT'
Thanks anyway! -
In material master standerd cost value not updating in group currency
hi gurus
In material master accounting 1 tab, under price and values table. standerd price is not updating in group currency.
Can you sugest me how to resolve this issue
this hapend only for one material
can you sugest me to resolve this
regards
gangadharHi,
As per My Knowledge,Wht ever currency is assigned as company code currency , tht will only be updated in Material Master as Per standard.
Currect me if Iam worng.
Thanks
Goutam -
In material master standerd price field not updating in group currency
In material master accounting 1 tab, under price and values table. standerd price is not updating in group currency.
Can you sugest me how to resolve this issueHi,
As per My Knowledge,Wht ever currency is assigned as company code currency , tht will only be updated in Material Master as Per standard.
Thanks
Goutam -
List price updation in Profit segment
Hi,
Could you explain how the List price-VV137 in CE1 table is getting updated in Profit segment???
Thanks and Regards
SankarCould you please respond this
Regards
Sankar -
EDI: Syntax error in IDoc (mandatory group/segment missing)
hi EDI/IDoc experts,
Need you help urgently. According to the requirement, i need populate a segement E1IDT01 of basic type PEXR2002 . I added the code , then run and generate an idoc , the new segment
E1IDT01 was populated, but Syntax error 26 happend. Error message as below. It also strange that i can see E1IDKU5 populate out as usual, but some others segment disappeared , i am sure that in my code ,i didn't changed any variable related to other segement . how can i fix this problem?
EDI: Syntax error in IDoc (mandatory group missing)
Message no. E0079
Diagnosis
The segment group E1IDKU5 has the attribute 'Mandatory' in the syntax description of the basic type PEXR2002 (customer enhancement ). However, the segment group is missing in the IDoc. The segment number logged in the status record identifies the item before which the segment group is missing.
Procedure
Please check the IDoc or the syntax description of the basic type PEXR2002 (customer enhancement ).Hi all,
Thanks so much for your concern!
Finally ,this problem has been figured out .
Requirement is user want to use segment E1IDT01 in idoc to populate the long text they maintained in accounting document vendor item line (use FB01 to create accounting doc).
Why I made out " EDI: Syntax error in IDoc (mandatory group/segment missing)" this message out ,because I didn't fill data correctly. I missed to keep SY-TABIX in momory .
when we use Function module ,or do..enddo...or read table it_table. we should be careful that SY-TABIX is changed .So we can't just use MODIFY EDIDD_TABLE INDEX SY-TABIX in the last . we should define a local variable to keep SY-TABIX in memory and then use it to modify EDIDD_TABLE.
Follow is the final code.
IF SEGMENT_NAME = 'E1IDT01'.
TABLES :STXL.
* Define for long text getting
DATA: LIT_TLINE LIKE TLINE OCCURS 0 WITH HEADER LINE.
DATA: LV_STRING(2000) TYPE C.
DATA: LV_TDNAME TYPE THEAD-TDNAME,
LV_ID TYPE THEAD-TDID VALUE '0001',
LV_LANG TYPE THEAD-TDSPRAS VALUE 'E' ,
LV_OBJ TYPE THEAD-TDOBJECT VALUE 'DOC_ITEM'.
data: LV_LINE TYPE I, " long Text lines
LV_LEN TYPE I, " long Text length
LV_TABIX LIKE SY-TABIX.
* Clear memory
CLEAR:LV_TDNAME,
LV_STRING,
LV_LINE,
LIT_TLINE, LIT_TLINE[],
LV_LEN,
LV_TABIX.
* Keep sy-tabix memory using a variable--This is the key point
LV_TABIX = SY-TABIX.
* Combine TDNAME with company code + accounting doc + fiscal year + item number.
CONCATENATE REGUP_DATA-BUKRS REGUP_DATA-BELNR
REGUP_DATA-GJAHR REGUP_DATA-BUZEI INTO LV_TDNAME.
* When vendor item has long text , read long text into lv_string
SELECT SINGLE *
FROM STXL
WHERE TDOBJECT = LV_OBJ
AND TDNAME = LV_TDNAME
AND TDID = LV_ID
AND TDSPRAS = 'E'.
IF SY-SUBRC = 0.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
ID = LV_ID
LANGUAGE = LV_LANG
NAME = LV_TDNAME
OBJECT = LV_OBJ
TABLES
LINES = LIT_TLINE.
IF NOT LIT_TLINE[] IS INITIAL.
DESCRIBE TABLE LIT_TLINE LINES LV_LINE.
DO LV_LINE TIMES.
READ TABLE LIT_TLINE INDEX SY-INDEX.
CONCATENATE LV_STRING LIT_TLINE-TDLINE INTO LV_STRING.
ENDDO.
LV_LEN = STRLEN( LV_STRING ).
* Make sure we only need less than 840 charicters
IF LV_LEN > 840.
LV_STRING = LV_STRING+0(840).
LV_LEN = 840.
ENDIF.
* Populate Vendor item long text with segment E1IDT01 start from
* Fields TXT03 to TXT14.
EDIDD_TABLE-SDATA+147(LV_LEN) = LV_STRING.
MODIFY EDIDD_TABLE INDEX LV_TABIX.
ENDIF.
ENDIF.
ENDIF. -
People/Group column in Datasheet View with ADFS Authentication.
Greetings,
We use ADFS & NTLM Authentication on our web application, but NTLM is only used to allow search to crawl the farm. So all users login and use their ADFS account when accessing the farm. When users are editing a list in Quick Edit/Datasheet
view when they try to edit a People/Group column they get "The user does not exist or is not unique." unless they enter in the full claim. e.g. "i:e0.t|adfs|[email protected]". The user will then resolve properly.
Has anyone else run across this or know how to solve this problem?
Thanks.Hi ,
For this issue, I'm trying to involve someone familiar with this topic to further look at it.
Thanks,
Eric
Eric Tao
TechNet Community Support -
Windows 2008 r2 Server: Cant update the group belonging
Hello,
I have a Windows 7 client computer which is administered by a Windows 2008 Server.
When I try to change the local grants of the user account in that client computer, it appears to me the following message:
"Cant update the group belonging for NameDomain\user"
As result I cant change local grants for the user. I cant change his status from administrator to user of that machine.
Can anybody tell me how can I solve this issue?
Thanks in advance
RegardsHi,
Thanks for your feedback. Did you mean that the issue exists after you removed
DameWare tools?
Please make sure that you have more than one administrator account on your computer, or you can't change it to a standard account since Windows requires at least one administrator account on a computer.
If you have another administrator account, you can try to use it to change the user’s account type.
Best regards,
Susie
Maybe you are looking for
-
Reporting Services: XML Data Source and Parameters
I’ve created an XML service (asmx) in ASP.Net that I want to use as a data source for an SQL Reporting Services report. The report and service work just fine if I use a Method from the service that does not have parameters. However, if I use a Method
-
How can I disable my account?, How can I disable my account?
I need to disable my account in apple
-
Flash Player question, Whats Apples opinion?
I just got a window suggesting I install Adobe Flash Player 11.8.800.94 What is Apple recommending about flash player I seem to recall it wasn't too happy with it, about a year or 2 ago?
-
Selected 'wallpaper' appears in Camera Roll
I have selected a particular image as my 'wallpaper' from the ones provided in my iPhone 3G. After syncing with my computer, that image appears in Camera Roll on my 'phone. How? Why? Shoukd it be doing that? It means that there is a danger that if I
-
Can mac os x disk utility program repair HD running 9.x?
Hi, I need to purchase Diskwarrior or a similar program to try to repair a "keys out of order" problem which is causing a flashing "?" in folder icon at start up (as reported by Disk First Aid). My question - can I purchase the Mac OS X version of Di