How do I read the last entry of an internal table? Assuming that sometimes the entries of the internal is not fixed as sometime it has 1,2,3, or 4 entries.
I want to read the the last entry of T_EKBE table. Sorting the Material Document Number is prohibited as the material document numbers is not always in sequential form. Here's my code and I believe that READ TABLE only selects the first entry.
READ TABLE t_ekko_ekpo ASSIGNING FIELD-SYMBOL(<lfs_ekko_ekpo>)
WITH KEY ebeln = t_ekbe-ebeln
ebelp = t_ekbe-ebelp
waers = t_ekbe-waers
Currently, the first line is being read here. I want the last line to be read instead.