2008 Dec 21 6:05 AM
Hi All,
My kind of requirement is in the function module AUFBAUEN_MDPSX_ANZEIGEN ther is a routine called SELECT_MDPB.
Here the query which is getting executed for my requirement.
*--> Anzeige mit Filter
SELECT * FROM mdpb
INTO mdpb
WHERE matnr EQ mdkp-matnr
AND werks EQ mdkp-plwrk
AND pdatu IN shorizon
AND vervs EQ xflag
AND plnmg NE 0. "Null-Saetze ignorieren
I dont want this vervs eq xflag in the above select query. so i want to remove this condition. since its a standard sap code can any one tell me whether it can be done through enhancement points.
Appreciate ur valuable answers.
Thanks
@run.
Hi All,
My kind of requirement is in the function module AUFBAUEN_MDPSX_ANZEIGEN ther is a routine called SELECT_MDPB.
Here the query which is getting executed for my requirement.
*--> Anzeige mit Filter
SELECT * FROM mdpb
INTO mdpb
WHERE matnr EQ mdkp-matnr
AND werks EQ mdkp-plwrk
AND pdatu IN shorizon
AND vervs EQ xflag
AND plnmg NE 0. "Null-Saetze ignorieren
I dont want this vervs eq xflag in the above select query. so i want to remove this condition. since its a standard sap code can any one tell me whether it can be done through enhancement points.
Appreciate ur valuable answers.
Thanks
@run.
2008 Dec 21 8:39 AM
Yes, ..Maybe, .. and No.
Yes - If the code is in a form, there is an implicit enhancement point at the beginning and end of each form. So if you want to you can put your own code in to the beginning of the form. If the form has lots more SAP standard code in it you may need to duplicate all this code, then put an EXIT statement at the end of your enhancement so the original version does not run as well.
Maybe - In some cases, SAP have flagged their code to say enhancements cannot be made to it - so if this function / form falls into that category you may not be allowed to enhance it.
No - What I describe for "Yes" is not a good way to modify any but the simplest type of form. The more standard SAP code you copy into the enhancement, the greater the chance that a future support pack or SAP Note will fix an error in the part of the code that is no longer used, and you will be running incorrect code without realising it - possibly corrupting data. If there is a real business need for the change, then the best way to do it is probably to get a key for the object and repair the code. That way SPAU will highlight the change when support stacks are applied and you will be able to re-evaluate the change for any new code.
Andrew
2008 Dec 22 7:48 PM
Hi Marshal,
Many Thanks for your answers.
I have copied the same routine and added after that and done some modification to meet my requirements. I have checked the code no syntax errors at all and added activated the routine.
When i try to debug the transactioN its not showing up my code what i have written over there,.
Can any one please let me know why its happening like this?
Thanks
Arun
2008 Dec 23 8:56 AM
Hi Arun,
You have to make sure that your copied routine or function module is called by SAP standard transaction that you use. It usually configured in SPRO if it is configurable. You can try to debug when calling the transaction and verify whether SAP still call the standard routine or your copied program.
If you havent done any configuration, unlikely the transaction will make use of your copied program.
However, there is no guarantee that SAP use dynamic call to function module in their program. Most of the time, function module name is already 'Hard-coded' inside SAP standard program. If that's the case, copying the routine is not enough to fulfil your requirement. Either you have to modify the routine directly using access key and modification assistant or you modify the program that called the function module.
Regards,
Abraham