Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ABAP dump CATCH_ILLEGAL_STATE while importing data from an internal table to multiple structures

ashissap1
Associate
Associate
0 Likes
2,715

Code is working in development and quality system as exception "cx_sy_import_mismatch_error" is occurring there and that has been handled by catching the exception. But issue is coming in Production system with runtime error "CATCH_ILLEGAL_STATE' and no exception is being raised.

ST22 Runtime Error:

Category: Internal kernel error

Runtime Errors: CATCH_ILLEGAL_STATE

Application Component: Not assigned

Before importing the data, internal table is getting filled properly and checked in debug mode. Internal table lt_vbdata has filed VBDATA which is of data type LRAW with length 30000

Please help to fix the issue

APPEND ls_vbdata TO lt_vbdata.
TRY .
    IMPORT
        iv_code          TO lv_code
        iv_coll          TO lv_coll
        is_lime_head     TO ls_lime_head
        is_hu_maint      TO ls_hu_maint
        it_guid_hu       TO lt_guid_hu
        it_quan          TO lt_quan
        it_litem         TO lt_litem
        it_lhuitm        TO lt_lhuitm
        it_ordim_c       TO lt_ordim_c
        it_ordim_cs      TO lt_ordim_cs
        it_ordim_canc    TO lt_ordim_canc
        it_ordim_h       TO lt_ordim_h
        it_ordim_hs      TO lt_ordim_hs
        it_ref           TO lt_ref
        it_huhdr         TO lt_huhdr
        it_phm           TO lt_phm
        it_huident       TO lt_huident
        it_qdocid_qdocno TO lt_qdocid_qdocno
        it_hu_diff2      TO lt_hu_diff2
      FROM INTERNAL TABLE lt_vbdata.
    CATCH
      cx_sy_import_mismatch_error .
  ENDTRY.

Code is working in development and quality system as exception "cx_sy_import_mismatch_error" is occurring there and that has been handled by catching the exception. But issue is coming in Production system with runtime error "CATCH_ILLEGAL_STATE' and no exception is being raised.

ST22 Runtime Error:

Category: Internal kernel error

Runtime Errors: CATCH_ILLEGAL_STATE

Application Component: Not assigned

Before importing the data, internal table is getting filled properly and checked in debug mode. Internal table lt_vbdata has filed VBDATA which is of data type LRAW with length 30000

Please help to fix the issue

APPEND ls_vbdata TO lt_vbdata.
TRY .
    IMPORT
        iv_code          TO lv_code
        iv_coll          TO lv_coll
        is_lime_head     TO ls_lime_head
        is_hu_maint      TO ls_hu_maint
        it_guid_hu       TO lt_guid_hu
        it_quan          TO lt_quan
        it_litem         TO lt_litem
        it_lhuitm        TO lt_lhuitm
        it_ordim_c       TO lt_ordim_c
        it_ordim_cs      TO lt_ordim_cs
        it_ordim_canc    TO lt_ordim_canc
        it_ordim_h       TO lt_ordim_h
        it_ordim_hs      TO lt_ordim_hs
        it_ref           TO lt_ref
        it_huhdr         TO lt_huhdr
        it_phm           TO lt_phm
        it_huident       TO lt_huident
        it_qdocid_qdocno TO lt_qdocid_qdocno
        it_hu_diff2      TO lt_hu_diff2
      FROM INTERNAL TABLE lt_vbdata.
    CATCH
      cx_sy_import_mismatch_error .
  ENDTRY.
3 REPLIES 3
Read only

former_member208149
Participant
1,343

Does you internal table lt_vbdata comply to the syntax and semantics of the IMPORT statement ?

Check this: IMPORT ... FROM INTERNAL TABLE itab

The first column of itab must have the data type s or i and the second column must have the type x. The only table category allowed for itabare standard tables without secondary table keys. The internal table must contain a data cluster created using the INTERNAL TABLE addition of the EXPORT statement; otherwise, a runtime error occurs. Note that the internal table in particular cannot be empty.

Non-compliance of lt_vbdata could be reason for the dump.

Read only

0 Likes
1,343

Thanks Sapeksh for your response.

The issue was coming because of data absence. Internal table lt_vbdata was not getting properly filled. More than 30000 characters data (means multiple rows in internal table lt_vbdata) was required to fill all the structures with import statement. Previously, only one row of lt_vbdata was used to fill the structures, that caused the issue.

Read only

Tulasi
Explorer
0 Likes
1,343

Hi Ashis,

How did you resolve this issue, currently I'm facing similar kind of issue on production system. We are reading text from STXL cluster table.

Any pointer would be helpful.

Thanks

Regards,
Tulasi