- Based on sorting technique internal tables can divided 3 types.
- Standard internal table.
- Sorted internal table.
- Hashed internal table.
Standard internal table.
- By default any internal table is standard internal table.
- This is follows linear search(one by one) algorithm.
- Searching time is proportional to number of records.
- Syntax :
Data : <internal table > TYPE STANDARD TABLE OF <TB /STR name> WITH NON-UNIQUE KEY <key > WITH HEADER LINE.
Sorted internal table.
- This is follows binary search help.
- It supports unique as well as no-unique key.
- Syntax :
Data : <internal table > TYPE SORTED TABLE OF <tab/str name>
WITH <UNIQUE / non-unique > KEY <keyname> WITH HEADER LINE .
Hashed internal table.
- There is no non-unique key.
- Its follows index based search.
- Syntax :
Data : <internal table > TYPE HASHED TABLE OF <TB/STR NAME>
WITH UNIQUE KEY <KEY> WITH HEADER LINE.
Note : WITH HEADER LINE is optional .
No comments:
Post a Comment