场景:
系统程序某个screen中的数据字段异常,其值是经过系统程序多次处理得到,这种情况下要求分析出数据的来源。
Debug方法(逐步逼近法):
1. 在screen的 PAI 起始处设断点
2. 在screen PAI处开始单步调试,找到目标数据变化的位置从而界定初始Debug范围,在变化前一位置设断点
3. 重启新一轮调试, 从上次最后设的断点处开始debug
4. 重复步骤2,3 直到找到最后的具体变化点
若数据在进入PAI之前数据已经变化成不期望的数据,可能过Call Stack上溯到以前的调用处并设断点,然后按上述debug方法操作. 另设断点时要善用ST05, (Field, Subroutine) Where-used, FIND来辅助找出可疑位置。
其它一些技术手段:
Watch-Point的使用(当变量=某值时进入Debug状态, 分析系统程序时非常有用!感谢波波):
Sometimes, an SAP process will stop working with an error message, or an abend. Unlike with a dump, it can be difficult to find exactly where the problem occured. What you should do, is get the technical name and number of the message - e.g. RS 100. Set a breakpoint at the start of the process (or run the process with the debugger switched on). As soon as the debugger is in some abap code, set a watchpoint for sy-msgno. In this example, you should set a watch point for sy-msgno = 100. Then hit F8.
The process will continue to run until sy-msgno has the value 100.
Check that the message ID is correct, according to the message - RS in this example. If it is, then you are at the place where the error occurs. You can usually back trace a few steps to find out precisely what was causing that error to be triggered.

原文地址: http://searchsap.techtarget.com/tip/0,289483,sid21_gci1314665,00.html
Active ITABs in Memory(Only in Classic Debugger)
1. In debug mode follow menu path: GOTO -> System Areas -> Internal Information
2. Enter "DSEG" to Area field
You will get a list of all the tables active in that program along with some other attributes. The type and size of the records determine if they are internal tables and how many records there are.
You can play around and try the other area than DSEG, some are interesting.
Memory Use
1. In debug mode follow menu path: GOTO->Status Display->Memory Use
2. Select tabstrip: Memory use
Ranked list You will see all variables used in the program sorted by size
分享到:
相关推荐
找到main program并设置断点,重新执行Smartforms以启动Debug。 七、Debug其他用户程序 使用外部断点模拟其他用户,例如/hext user=U0043267,然后运行目标程序,捕获指定用户的操作。 以上就是SAP ABAP调试的综合...
#### 六、连接远程SAP NetWeaver Gateway System 1. **创建目的地**:在SAP Web IDE中创建一个目的地以连接到远程SAP NetWeaver Gateway系统。可以通过SAP Web IDE中的“Destination”功能实现。 2. **消费oData服务...
#### Debug ip x sap - **功能**:显示关于SAP(业务通告协议)更新数据包信息。 - **用途**:监控SAP协议的工作情况,确保业务通告正常进行。 #### Debug isdn q921 - **功能**:显示在路由器D通道ISDN接口上发生...
- **用途**: 配置高级程序到网络 (Advanced Program-to-Program Networking, APPN) 系统。 - **示例**: `appn system` **6. Atmsig** - **用途**: 配置 ATM 信号协议。 - **示例**: `atmsig enable` **7. ...
**Appn**: 配置高级程序到网络(Advanced Program to Network, APPN)系统,这是一种IBM开发的企业级网络架构。 **Atmsig**: 设置ATM(Asynchronous Transfer Mode, 异步传输模式)信号协议,用于在ATM网络中传输...