Hello,

With the IS-PS-CA 617 release, a new codes was added inside of “UPDATE_PRE_EXC_ABSENCE” form which is called by “HRIQ_EVENT_CHANGE” function module as a part of  pre excused absences process.

Through that when a user edits event offerings (change resources assigned to an event , edit schedules of events etc…) by calling PIQACADOFFER00 t-code, this new code deletes all contents of PIQDBATATT table so all attendance tracking master data was lost.

As a solution SAP serviced 2 notes which numbers are;

0002086214

0002166136

Related Function Moduels: HRIQ_EVENT_CHANGE

Related Include:                LHRPIQ00MODULEOFFER_CREATEF05

Related Form:                   update_pre_exc_absence

*  –>  p1        text
*  <–  p2        text
*———————————————————————-*
* (call after delete_inftys_from_e in HRIQ_EVENT_CHANGE)
FORM update_pre_exc_absence USING pv_objid TYPE hrobjid
pt_schedule
TYPE piq_bapisched_t.
DATA: lt_att TYPE TABLE OF piqdbatatt,
lt_att_new
TYPE TABLE OF PIQATEVENTOCCATTEND,
ls_att
TYPE piqdbatatt.
DATA: lt_preex TYPE TABLE OF piqdbatpreex,
ls_preex
TYPE piqdbatpreex.
DATA: ls_schedule LIKE LINE OF pt_schedule.
FIELD-SYMBOLS: <fs_att> TYPE piqdbatatt.

*  SELECT * FROM piqdbatatt INTO TABLE lt_att
*    WHERE EVENT_OBJID = pv_objid.
*  SORT lt_att BY st_objid EVENT_DATE BEG_TIME.

* in case of event creation, pre-exc absence DB table is updated
SELECT * FROM piqdbatpreex INTO TABLE lt_preex
FOR ALL ENTRIES IN pt_schedule
WHERE beg_date <= pt_scheduleevdat
AND end_date >= pt_scheduleevdat
.

LOOP AT lt_preex INTO ls_preex .
LOOP AT pt_schedule INTO ls_schedule WHERE evdat >= ls_preexbeg_date AND evdat <= ls_preexend_date.
ls_att
PLVAR = ls_preexplvar.
ls_att
ST_OBJID = ls_preexst_objid.
ls_att
EVENT_OBJID = pv_objid.
ls_att
EVENT_DATE = ls_scheduleevdat.
ls_att
BEG_TIME = ls_schedulebeguz.
ls_att
ABSENCE_RSN = ls_preexabsence_rsn.
ls_att
AEDTM = sydatum.
ls_att
UNAME = syuname.
APPEND ls_att TO lt_att_new.
ENDLOOP.
ENDLOOP.

“Update PIQDBATATT for pre-exc absences events
SELECT * FROM piqdbatatt INTO TABLE lt_att
FOR ALL ENTRIES IN lt_att_new
WHERE st_objid = lt_att_newst_objid AND event_objid = lt_att_newevent_objid.
DELETE piqdbatatt FROM TABLE lt_att.” WHERE st_objid = lt_att_new-st_objid AND event_objid = lt_att_new-event_objid.
MODIFY piqdbatatt FROM TABLE lt_att_new .

ENDFORM.                    ” UPDATE_ATTENDANCE




Best regards.

SLcM App. Consultant Görkem

To report this post you need to login first.

Be the first to leave a comment

You must be Logged on to comment or reply to a post.

Leave a Reply