您的位置:首页 > 其它

BINARY SEARCH in read table statement

2014-03-11 19:07 423 查看
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.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: