cancel
Showing results for 
Search instead for 
Did you mean: 

GENERIC EXTRACTION DELTA SETTINGS

Former Member
0 Kudos

HI Everyone,

I need to know how we set up Generic Delta in the following scenarios.

1) When we have a Generic Extractor based on a View and this View has multiple table(For Example 2 Tables to start with).

Then how wil you have the Generic Delta based on which field from which table? FOr example Table 1 has Header Data and Table2 has Item Data.Our Functional Consultant says Header can change or Item data can change.So we need to pick up the record based on the change in each of the tables. For Example , there is a field called CHANGED DATE(AENDT) which is present in both the tables. Now , in the view if I add AENDT from Table1, then Table1's chnages will only be updated i guess. What if the change occurs in TABLE2 (ITEM).

I dont know how to go about this. The solution is I created two Generic Extractors with two views (The only difference between the views is AENDT field coming from TABLE1 in the first extractor and AENDT field coming from TABEL2 in the second Extractor).But I think this is not the best way and there must be an alternative for this

2) The other issue is If I have a Function Module which Brings data from Multiple Tables, then how to select the field on which Delta is set.Do we need to write some Logic. After writing the logic, can we directly set the Generic Delta in RSO2 or is there any other way to do it.

Regards,

Samir

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Samir,

We too had a simliar requirement. In your case you can create a FM generic datasource on top of the view. The view in your case will get the intersection of the Header and Item level data. the main challenge was to get the delta records as we can have both Orders created and changed , and in Delta can be maintained on only one field.

To overcome this issue in the FM coding, Steps:

create Generic datasource, with Delta on changed on date (AENDT)

So during extraction you get the date on which the last Load was succesfully completed using the (AENDT).

So in the selection part use the statement similar to this:

select * from vbap into table it_order where

( erdat in l_r_erdat or aedat in l_r_zaedat ) and

( erdat in l_r_aedat or aedat in l_r_aedat )

Sample generic datasource for your reference:

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/403b299b-94e5-2c10-a3b4-e2cecb8ee...

Hope this helps.

Regards,

Umesh.

Answers (3)

Answers (3)

Former Member
0 Kudos

Closed

Former Member
0 Kudos

Hi Sameer,

Find the document below it may help you.

http://www.sapdb.info/wp-content/uploads/2009/09/Generic-Extraction.pdf

Regards,

Shiva Kumar G.C

Former Member
0 Kudos

I guess you have already joined the table fields in view, when there is a change in table one or two will pick up the delta.

There will not be problem in captruing the delta based on the changed date.

Hope this helps.

Regards,

Reddy

Former Member
0 Kudos

Hi Reddy,

But, I have picked up the changed date (AENDT) field from Table1. SO, If something changes in table1, then it will update.

When u select the fields after u specify the Join Conditions, u need to select individual fields from individual tables R8. So at this time, I picked up AENDT from Table1. So how this will bring the changes from Table2?

Regards,

samir

Former Member
0 Kudos

Hi Everyone,

Any Updates on this?

Regards,

Samir

Former Member
0 Kudos

Hi,

Here we need to decide the delta-relevant field based on the extraction.

Calender day

Numeric Pointer

Time stamp

Calday u2013 if we setup delta on base of calday we can run delta only once per day that to at the end of the clock to minimize the missing of delta records.

Numeric pointer u2013 This type of delta is suitable only when we are extracting data from a table which supports only creation of new records, but not change of exiting records.

Time stamp u2013 Using timestamp we can run delta multiple times per day but we need to use the safety lower limit and safety upper limit with minimum of 5 minutes.

Based on your report reuirement and the possible fields avialable in the datasource you need to decide which field you need make delta-relevant.

Hope it clear.

Any queries please get back.

Thanks,

Former Member
0 Kudos

Hi,

I think I know these basics. But the question I have asked is a bit different. How to update the changes in the two underlying tables in a view. so that the changes are not missed from any of the Tables.BOth of them have Changed Data Field.

Regards,

Samir

former_member186445
Active Contributor
0 Kudos

as discussed before...

1.

rso2 - delta enabled ds will pick up delta only for one choosen field...if there are more fields in your view that can indicate a change, you need to have more ds if you want to use the delta enabling in rso2...

2.

an other option : create a program that reads all the tables that you need, check the timestamps since last program run, and put all these records in a new table. base your extractor on this table; the extraction will be a full load, but the data coming over will actual be a delta load

3.

if you use a function module as base for your extractor, you can't make it delta enabled in RSO2. So you need to handle the delta part in your FM...

if you search the forum you'll find many posting concerning this topic, even with complete codings...

please do so before posting once again the same question.

once you have specific questions/problems while creating this FM, you can post them here

M.

former_member186445
Active Contributor
0 Kudos

about FM delta's

/people/siegfried.szameitat/blog/2005/09/29/generic-extraction-via-function-module

Former Member
0 Kudos

Hi,

if you have view(Database view) based on 'N' no.of tables underlying in it. at the time of filling the tables same time view also getting the data by default (it won't fill seperately).

it may help for your question

Thanks

Edited by: satya prasad on Apr 1, 2010 12:54 PM