External Debugging from EP (Enterprise Portal) and SRM Portal in SRM System

When we encounter errors/issues in an SRM document (like POs, shopping cart and SRM/EP related SAP objects), then we usually login to the SRM or EP portal to access these corresponding document. In order to analyze further - we also have to check the SRM system to crosscheck if the issue is with any custom code put into the BADI’s (Business AddIns).
To debug this scenario we would have to perform certain set of activity that is causing the error like ordering the PO etc. in the portal login which then calls the SRM system where the actual processing is done. To achieve this we will be using the external debugging option that SAP has provided. (In other words, we can say that to find the RCA we have to debug the SRM/EP objects in their corresponding landscape and that require few settings as explained below).