Skip to Content
Former Member
Feb 09, 2011 at 06:16 AM

Length mismatch for NAST-OBJKY and EKKO-EBELN


Hi All,

I am using Table NAST,and by using FOR ALL Entries with table ekko I am trying to use OBJKY = it_ekko-ebeln.But I am getting error message as length is different.when i checked OBJKY is of length 25 and EBELN is of lenght 10.Please help me to solve this problem.I tried to take a local variable but I am not able to use it.

here is my code


SELECT kappl " Application for message conditions

objky " Object Key

kschl " Message type

spras " Message language

parnr " Message partner

parvw " Partner function

erdat " Date on which status record was created

eruhr " Time at which status record was created

vstat " Processing status of message

FROM nast

INTO TABLE it_nast

  • FOR ALL ENTRIES IN it_ekko

WHERE kappl = gc_apps

  • AND objky = it_ekko-ebeln

AND kschl IN s_kschl.

IF sy-subrc = 0.

SORT gt_nast BY kappl objky.