cancel
Showing results for 
Search instead for 
Did you mean: 

DS 4.2 get ECC CDHDR deltas in ABAP data flow using last run log table

brad_schroeter2
Explorer
0 Kudos

I have a DS 4.2 batch job where I'm trying to get ECC CDHDR deltas inside an ABAP data flow.  My SQL Server log table has an ECC CDHDR last_run_date_time (e.g. '6/6/2014 10:10:00') where I select it at the start of the DS 4.2 batch job run and then update it to the last run date/time at the end of the DS 4.2 batch job run.

The problem is that CDHDR has the date (UDATE) and time (UTIME) in separate fields and inside an ABAP data flow there are limited DS functions.  For example, outside of the ABAP data flow I could use the DS function concat_date_time for UDATE and UTIME so that I could have a where clause of 'concat

_date_time(UDATE, UTIME) > last_run_date_time and concat_date_time(UDATE, UTIME) <= current_run_date_time'.  However, inside the ABAP data flow the DS function concat_date_time is not available.  Is there some way to concatenate UDATE + UTIME inside an ABAP data flow?

Any help is appreciated.

Thanks,

Brad

View Entire Topic
brad_schroeter2
Explorer
0 Kudos

FYI...a co-worker helped me resolve my issue.  I set both $CDHDR_Last_Run_Date_Time and $Run_Date_Time to varchar(14) and in the format of 'YYYYMMDDHHMISS'.

Then here's my ABAP data flow where clause:

CDHDR.OBJECTCLAS in ('DEBI', 'KRED', 'MATERIAL')

and ((CDHDR.UDATE || CDHDR.UTIME) > $CDHDR_Last_Run_Date_Time_Char)

and ((CDHDR.UDATE || CDHDR.UTIME) <= $Run_Date_Time_Char)

Here's selected contents of the generated ABAP file (*.aba):

PARAMETER $PARAM1(14) TYPE C.

PARAMETER $PARAM2(14) TYPE C.

...

DATA ALTMP1(512) TYPE C.

DATA ALTMP2(512) TYPE C.

...

concatenate CDHDR-UDATE CDHDR-UTIME into ALTMP1.

concatenate CDHDR-UDATE CDHDR-UTIME into ALTMP2.

IF ( ( ALTMP2 <= $PARAM2 )

AND ( ALTMP1 > $PARAM1 ) ).

Since in the generated ABAP file all of the fields are varchar with concatenated date and time, I can easily pull the CDHDR deltas.

-Brad