BINARY SEARCH in read table statement详解编程语言

1.for standard table, it must be sorted by search key.
2.for sorted table , binary search is used automatically when searching with/include table key. 

Note:with a binary search (addition BINARY SEARCH is used for standard tables, automatically for sorted tables), if there are several hits (because of an incompletely specified search key or because there are duplicate entries in the table), then the first hit in terms of the sequence of the rows is always returned, that is, the row with the smallest index.

        using binary search,if there is no records hitted , then sy-subrc is set to 4, sy-tabix is set to 1,
        if there is no record hitted and  the end of the table was reached, sy-subrc is set to 8, sy-tabix is set to lines of table + 1.

原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/18327.html

(0)
上一篇 2021年7月19日
下一篇 2021年7月19日

相关推荐

发表回复

登录后才能评论