cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

TEVEN table Entries ( Infotype 2011 )

former_member209696
Participant
0 Kudos
5,235

Hi Experts,

I am trying to pull data from TEVEN Table for a reporting purpose. But I doubt there are some discrepancy in the table entries.

In our scenario, the data from the Time Keeping System will update in custom table every day at 7:00 : 00 AM

And TEVEN table get updated from the custom table at 07:15:00 AM .

The entries which found in the TEVEN table is as shown below.

Cl.NumberPers.No.Log.dateTimeCreatd onCreateAtTETTIDDAOTUser NameChanged on
20043012103/3/20158:17:00 AM3/3/20157:15:17 AMP100003= BATCH_USR3/4/2015
20043032103/3/20153:23:00 PM3/3/20157:15:17 AMP200004= BATCH_USR3/4/2015

As per above entries :

Employee 210 SWIPED IN on 03/03/2015 at 8:17:00 AM ( Log. Date & Time )

But Created on & Created at is 03/03/2015 at 7:15:17 AM ( Entry created before employee swipe in. Please correct if I am wrong ). Is this data is correct? If it is correct how can I get the exact Date and Time when the entry is created in SAP.

My functional consultant stating that this is a STANDARD SAP behavior and We should consider Changed On and Created at to get the exact Date time of the data entry creation.

I strongly believe that we need to correct the upload program first to get correct created date and created time of the data entry. Please correct me if I am wrong in any of these points.

Also help me with detailed meaning of created on & created time fields of TEVEN table.

View Entire Topic
sivakumar_mobility
Active Participant
0 Kudos

Hi,

I have facing  exactly what you are facing issue now while I am doing clock In and Clock out application. It is because of time deviation between our Local computer  time and SAP application server time.

For that You have to do some calculation which I marked in block.

Note:

You can calculate according to your Deviation.I got 26 minutes deviation.


DATA: LS_P2011          TYPE P2011,

           BAPIRETURN1       TYPE BAPIRETURN1,

          BAPIPAKEY           TYPE BAPIPAKEY.

LS_P2011-PERNR = LV_PERNR.

LS_P2011-LDATE = SY-DATUM.

  LS_P2011-LTIME = SY-UZEIT + ( 26 * 60 ) .

LS_P2011-SATZA = 'P10'.

CALL FUNCTION 'HR_INFOTYPE_OPERATION'

       EXPORTING

         INFTY            = '2011'

         NUMBER           = LS_P2011-PERNR

*       SUBTYPE          =

*       OBJECTID         =

*       LOCKINDICATOR    =

*       VALIDITYEND      =

*       VALIDITYBEGIN    =

*       RECORDNUMBER     =

         RECORD           = LS_P2011

         OPERATION        = 'INS'

         TCLAS            = 'A'

         DIALOG_MODE      = '0'

         NOCOMMIT         = ''

*       VIEW_IDENTIFIER  =

*       SECONDARY_RECORD =

       IMPORTING

         RETURN           = BAPIRETURN1

         KEY              = BAPIPAKEY.

     .

with Regards,

Siva.

.

Message was edited by: sivakumar M

former_member209696
Participant
0 Kudos

       gwa_timeevent-ldate = gwa_tks_sap-event_date.  " Log Date

       gwa_timeevent-ltime = gwa_tks_sap-event_time.  " Log Time

       IF  gwa_tks_sap-terminal_id EQ gc_09.                   

         gwa_timeevent-erdat = gwa_tks_sap-event_date.

       ELSE.

         gwa_timeevent-erdat = gwa_tks_sap-date_created.

       ENDIF.

       gwa_timeevent-ertim = sy-uzeit.



Is this piece of code is correct? GWA_TKS_SAP is workarea which holding Custom table value. If Terminal is 9 it is passing Log date as created date else it is passing created date which stored in Z table. terminal 9 entries are marked as P60 (information) entries. What it means?


Log date is passing ERDAT the time should also pass as Log time right?

sivakumar_mobility
Active Participant
0 Kudos

Hi,


Please Change the code like given below and check.



     gwa_timeevent-ldate = gwa_tks_sap-event_date.  " Log Date

       gwa_timeevent-ltime = gwa_tks_sap-event_time.  " Log Time

       IF  gwa_tks_sap-terminal_id EQ gc_09.                  

         gwa_timeevent-erdat = gwa_tks_sap-event_date.

       ELSE.

         gwa_timeevent-erdat = gwa_tks_sap-date_created.

       ENDIF.

       gwa_timeevent-ertim = sy-uzeit  - ( 15 * 60 ) .



former_member209696
Participant
0 Kudos

HI,

How you finalize 15 min deviation? You are mentioning something else I guess

sivakumar_mobility
Active Participant
0 Kudos

Hi Riyas,

I am sure that Its because of deviation only. Because I also worked as a Abaper , Its working fine in production.

Ask your Abaper to help you .Its because of two different systems only as per Ravi also.

With Regards,

Siva.