下面简单介绍一下如何在abap语言中定义一个嵌套内表(nested internal table),也就是内表中的一个字段也是内表。 1, SE11中定义一个表类型 这里找了一个SAP标准的表类型EKKO_TTY 2, 定义内表时使用table type 例子代码如下,其中字段podata就是嵌套的另外一个表。 REPORTztest_deep_it.TYPES:BEGINOFty_po, ...
一. Internal Table 的宣告 ABAP/4中的Internal Table是一种Data Structure,类似于其它语言中的STRUTURE,它可以由几个不同类型的字段(field)组成,用来表示具有不同属性的某一事物,单独一笔数据表示某个事物,多笔数据表示具有相同属性的多个事物.例如: 为了存取或记录某班的同学资料,我们创建如下的internal table: DA...
internal table 中文叫做内表,本质是一个多行的容器,类似C#里一个结构的数组。work area 中文叫做工作区,它是内表的一个行,类似C#里的一个结构。之所以经常给内表定义工作区,是为了操作内表数据方便,因为虽然内表有多行数据,但是你一次只能针对一条数据来处理,这条数据就放在工作区。
DATA:EMPTAB4 LIKE SORTED TABLE OF EMPTAB WITH UNIQUE KEY NAME INITIAL SIZE 10 WITH HEADER LINE. *定义一个初始化大小为0的哈希表 DATA:EMPTAB5 LIKE HASHED TABLE OF EMPTAB WITH UNIQYE KEY NAME WITH HEADER LINE. 通过第三种方式定义的内表可指定具体字段及初始化大小,默认内表存在HEADER LINE。 ...
Incorrect sorting of the rows in an internal table. 发生了什么? Error in the ABAP application program. The current ABAP program "SAPLMG26" had to be terminated because it found a statement that could not be executed. 错误分析 In the ABAP Debugger, the switch for monitoring the sorting of...
下面简单介绍一下如何在abap语言中定义一个嵌套内表(nested internal table),也就是内表中的一个字段也是内表。 1, SE11中定义一个表类型 这里找了一个SAP标准的表类型EKKO_TTY 2, 定义内表时使用table type 例子代码如下,其中字段podata就是嵌套的另外一个表。
You can use the DATA statement to construct new internal tables as well as using the LIKE or TYPEaddition to refer to existing types or objects. The table type that you construct does not exist in its own right; instead, it is only an attribute of the table object. You can refer to ...
Incorrect sorting of the rows in an internal table. 发生了什么? Error in the ABAP application program. The current ABAP program "SAPLMG26" had to be terminated because it found a statement that could not be executed. 错误分析 In the ABAP Debugger, the switch for monitoring the sorting of...
以前我们一般先定义internal table与work area,7.4以后,我们可以在对内表的操作过程中定义work area及field symbol。 DATA:monster_numberTYPEzde_monster_number VALUE'000000001',table_of_monstersTYPESTANDARDTABLEOFztsm_monsters.READTABLEtable_of_monstersWITHKEYmonster_number=monster_numberINTODATA(monster_details...
Note:that it is not necessary to declare the initial size of the table: sap’s memory management allows the table to be ‘infinitely’ extensible. Use of Internal Table Internal tables can be used as: Snapshots of database tables Containers for volatile data ...