SAP Database - The Unofficial SAP Knowledge Base

Free Business and Tech Magazines and eBooks

How to Modify the code in Quality or Production Systems?

Print This Post Email This Post Written by admin on Mar 31st, 2008 | Filed under: SAP General, Tips & Tricks

How to modify any code in Quality or Production without the need for a access key.

Imagine, you are doing a unit test for a object in QA, suddenly a test case fails and oh! come one you have to change this one line again in development and move it to Quality to test. That will take definetly at least 5 minutes to 30 minutes, depending on how your system is configured. How about changing the code directly in quality and continuing the testing. One little suggestion before we proceed with the tutorial, always use this trick only in quality and not in production or it may create chaos. I work on 4.6c and have not used this trick in all the other sap versions. Please try it and let me know your comments.

When you click on the change button in quality, you will get a screen like this saying ‘Error in Object Editing’.

Error in editing object

Now, we will work out a way to skip this message and make the change to the code. You will need this handy debugger to start the debugger from a popup.

Drag the debug tool and place it on the above popup. then, Click Continue or Press Enter. This will take you into ABAP Debugger. Click on Call stack button –> double click on Function TRINT_CORR_CHECK. ABAP Debugger
Now click on Fields button and then set a break point on the line LV_SUBRC = SY-SUBRC ( see image below) after the call to the function module ‘TRINT_CORR_CHECK’.

ABAP Debugger 2

Press F8 and the code will stop on the line ‘LV_SUBRC = SY-SUBRC’. Double click on SY-SUBRC and the value must be ‘12′ now change the value to ‘0′. Now, press F8 again, this should bring you back to the editor with change mode.

Wait, there is an another step to it. Once you edit the code and make the changes and press activate. The program will again bring you to the same window saying ‘Error in Editing Object’.
Error in editing object

Now, again drag and drop our little Debug Tool. Then click continue or press enter. This will take you to the ABAP Debugger, well this is a similar code, but it’s a different include so you have to carry the steps again. Click on Call stack button –> double click on Function TRINT_CORR_CHECK. Now, you will get a screen like below.

ABAP Debugger 3

Now, set the break-point at line ‘When 0′. Press F8 and now change the value of SY-SUBRC from ‘12′ to ‘0′.

Press F8(execute) and now the program will going through a set of break-points set by you. Change the value everytime from ‘12′ to ‘0′ and press F8. Finally after three or four execute sy-subrc changes, the program will finally get activate and you will have the new modified code available to execute.

Do you know about the syntax ‘INSERT REPORT‘. We can also modify the code using it.

Copyright SAP Database : This article can be reproduced as long as this line stays.

If you like this post, you may as well like these too:

  1. Transaction Code to Access Other Transaction Code with Values Many times in SAP, you may come across situations where in the users wants to have a separate transaction codes for some of the tables which can be easily maintained...
  2. SAP Project Systems Overview learn about SAP Project Systems (SAP PS): Organizational Units & Project Cycle Project Structures Planning and Budgeting Materials and Services Scheduling Execution Period End Closing Information System Download the presentation...
  3. SAP Quality Management Collection of all the SAP Quality Management(QM) help files. QM Basic Data Defects Recording QM In Production Dynamic Modification of the Inspection Scope Inspection Data Interface Inspection Lot Completion Inspection...
  4. Quality Notifications Understand about Create a notification for: Internal Complaint Customer Complaint –With Assignment Vendor Complaint Change notification and add detail data Release tasks and add activities to a notification Complete a...
  5. Quality Certificates You will learn about Create a Quality Certificate for a Customer Delivery Create a Quality Certificate in Procurement Use a Worklist for Certificates in Procurement Print a Quality Certificate Download...



This website uses IntenseDebate comments, but they are not currently loaded because either your browser doesn't support JavaScript, or they didn't load fast enough.

One Response to “How to Modify the code in Quality or Production Systems?”

  1. It works! Now i can play a lot in the QA system.

Leave a Reply

  • Subscribe to RSS

  • Free Ebooks