on 12-13-2013 9:03 AM
Hi Experts,
In start routine and end routine which one provides the better performance and how it effects the performance? Could you please explain it with a scenario...?
Thanks,
CS Reddy.
Hi Reddy,
There is no such criteria of performance while using Start routine or End routine, its all about the requirement of data modelling.
if you are using Field routine for multiple fields in transformation or your Field routine has CRUD(Create, Read, Update, Delete) statements on database table then we can surely say that it will impact on performance and Start routine or End routine is recommended in such cases.
There are some specific requirements based on which we decide to whether go for Start routine or End routine.
Start routine usage:
Filtering the data coming from source in source_package.
Mass modification of source data.
Third party data extraction (other infoprovider) for look up purpose.
End routine usage:
Filteration of data based on target attribute values.
New data creation in result_package. etc.
Hope this will help you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi CS,
I totally agree with all the answers above.
But one more thing to add is if you have more no of fields which are not direct mapping then i prefer using Expert Routine. I got a scenario where there are 98 fields,around 6 Lookup tables,lot of calculation,conditions available where direct mapping is for only 15 fields then i used expert routine.
SAP says to be cautious while using Expert routine but for above situation that was preferred one.
It also depends on the data you have.
Finally You cant judge whether start routine or end routine is preferable directly on performance wise.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Reddy,
START ROUTINES can be used to process the data efficiently prior in starting the single record processing - This is best place to delete/ filter records from the data package before spending time in processing them,.
END ROUTINES allows to process the data after it has been processed thro transformation and this is the best place to copy data records like generating year to date figures.
If the logic doesnt demand filtering activities, we can have the logic written in End routine.
However we need to tune in Best ABAP for performance activities in the code.
Regards,
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
search in sdn you will get many document.Start routines will run for each and every data package. start Routine contains same structure of the source as input and output parameters. SOURCE_PACKAGE contains contents of source data.
RESULT_PACKAGE contains process data i.e. processed via start routine and transformation. RESULT_PACKAGE has same structure as that of target Object.for more information refer this document.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Reddy,
As we all know, both start routines and end routines process records package by package. Field routines process record by record and not package wise. So in this point there is huge difference in between start routine / end routine on one side and field routine on one side. But as per your query in this regards I don't see any difference in between start and end routine on performance view.
The number of records processed in start routine lets say 1000, and if we have a requirement to split 1 rec into different 4 records, depending on % of some KF, or SKU --> different parts. Then in this way, by the time the end routine process, the number of records may be increased to 4000, hence in this regards you might see less performance in End routine. If we take other way around like if there 1000 records where only 2 records are of country INDIA, and you require only records that belongs to INDIA, so in start routine you delete 998 records and by the time end routine process we have only 2 records. So as per this requirement, we can see less performance in start routine. If we consider more records we might see some difference in performance. But to be frank, in this matter, I don't consider that there may be that much viewable difference in these routines, as they both process package by package.
So the next point I would consider is ABAP code. Both these routines are based on the code written by us. So if we have perfect path of executable code, then we don't see much difference here as well.. But it all depends on developers who write the code and above all points are dependent on system performance as well.
Thanks,
-Mike.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Mike:
Both routines have a well difene purpose. The Start routine is basically for cleaning data. Here you can massage the data such as getting rid of some unwanted data, format KF, etc. The end routine is for transforming data. I believe here where you want to multiply your records. The package will delive the data to the start routine then it will go to the individual routines. Sure there is a cost penalty here as every record must to the individual rules. The most efficient way to transform data is in the end routine. From release 7, you can use the expert routine bypassing the previous routines.
Regards
RAP
Hi,
Start and End routines are just placeholders for you to enter custom code; neither of them is inherently slow or fast. It all depends on how you use them.
For instance, if your business rules say that certain data needs to be deleted/discarded while loading, I'd try to achieve that in the Start Routine. That removes a good chunk of data right at the beginning thereby reducing the amount of data going into the field rules and the end routine. Beyond that they're fairly interchangeable from a performance standpoint.
Regards,
Suhas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Csr,
Start/end routines both are not the same. its depend on requirement we need to use them.
Performance both will be the same. but its depend the statements/code which we use to fill the data to target objects. for more information you can get from Google search.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Reddy,
Depends on the logic you wanted to do, start routine does the logic before data comes in and end routine does after the data is extracted.
Refer this Document for more info.
Regards,
Suman T
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That depends upon how many fields are processed in SOURCE_PACKAGE (start routine) and RESULT_PACKAGE (end routine).
Start or End routine has no direct impact on performance but in turn based on the fashion in which fields are populated.
Br, H
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
92 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.