Skip to Content
0
Former Member
Oct 28, 2009 at 05:34 PM

Sorted table filled but not in key sequence

46 Views

Hello Experts,

I have an issue with Sorted Table. The table is filled but not in the key order!!!!! Is filled like a simple append.

In my program i did the following:

I declare a type, a sorted table and i fill it with insert into.

TYPES: BEGIN OF ty_doc.

TYPES:

bukrs_d TYPE bukrs,

blart TYPE blart,

budat TYPE budat,

bldat TYPE bldat,

monat TYPE monat,

waers TYPE waers,

kursf TYPE kursf,

xblnr TYPE xblnr1,

bktxt TYPE bktxt,

xblnr_s TYPE xblnr1.

TYPES: postes LIKE bseg OCCURS 0.

TYPES: END OF ty_doc.

Data: t_doc TYPE SORTED TABLE OF ty_doc WITH NON-UNIQUE KEY

bukrs_d, blart, budat, bldat, monat, waers, kursf, xblnr,

bktxt.

I changed the data type of budat, blart, monat, waers and kursf to CHAR even so doesn't work.

Do you have any idea about this problem? Why the table is not filled in the key sequence since i declared it sorted?

Thank you in advance !!