Skip to Content
avatar image
Former Member

ALV Runtime Error : "NO_FIELDCATALOG_AVAILABLE"

Hi,

I am getting an error : "CL_GUI_ALV_GRID===============CM01J

" "SET_SORT_CRITERIA".

The program works fine in 4.6 but in 4.7 it is terminating.

*****************************************************

ERROR DESCRIPTION.

<b>Error analysis </b>

A RAISE statement in the program "CL_GUI_ALV_GRID===============CP" raised the

exception

condition "NO_FIELDCATALOG_AVAILABLE".

Since the exception was not intercepted by a superior program

in the hierarchy, processing was terminated.

Short description of exception condition:

For detailed documentation of the exception condition, use

Transaction SE37 (Function Library). You can take the called

function module from the display of active calls.

-

<b>Information on where terminated </b>

The termination occurred in the ABAP program "CL_GUI_ALV_GRID===============CP"

in "SET_SORT_CRITERIA".

The main program was "Z7IPPLRP_ZNAV_MSREPORT ".

The termination occurred in line 14 of the source code of the (Include)

program "CL_GUI_ALV_GRID===============CM01J"

of the source code of program "CL_GUI_ALV_GRID===============CM01J" (when

calling the editor 140).

<b>Source code extract</b>

000010 method set_sort_criteria.

000020

000030 *... (1) Trace?

000040 if not mr_trace is initial.

000050 call method mr_trace->add_trace_item

000060 exporting

000070 i_trace_item = 'SET_SORT_CRITERIA'

000080 ir_variant = m_cl_variant

000090 it_data = mt_data

000100 it_info = mt_info.

000110 endif.

000120

000130 if m_cl_variant->mt_fieldcatalog is initial.

> raise no_fieldcatalog_available.

000150 endif.

000160

000170 m_cl_variant->mt_sort = it_sort.

000180

000190 call function 'LVC_SORT_COMPLETE'

000200 exporting

000210 it_fieldcat = m_cl_variant->mt_fieldcatalog

000220 changing

000230 ct_sort = m_cl_variant->mt_sort.

000240

000250 endmethod.

*****************************************************

Any ideas ?

Thanks & Regards,

Ankur

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Best Answer
    Oct 17, 2005 at 02:59 PM

    Does your program use a "hardcoded" or predetermined layout variant? Looks like the program may be having a hard time setting up the ALV Grid layout.

    Regards,

    Rich Heilman

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 17, 2005 at 03:05 PM
    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 17, 2005 at 03:09 PM

    Check if when calling the method SET_TABLE_FOR_FIRST_DISPLAY , you are passing a valid field catalog to "IT_FIELDCATALOG" or if you are passing a structure to the parameter "I_STRUCTURE_NAME" and this structure does not exist in your system.

    Cheers .

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Srinivas Adavi

      Hi Srinivas,

      Yes I completely agree with you.

      Sanjay deserves a lot more than the link below.

      /people/mark.finnern/blog/2005/10/10/small-announcements

      Well done Sanjay.

      Best Regards,

      Ankur

  • avatar image
    Former Member
    Oct 17, 2005 at 03:33 PM

    Hi,

    I don't know this particular error situation; just a hint: If you don't pass a fieldcatalog to the SET_TABLE_FOR_FIRST_DISPLAY Method, it is determined by I_STRUCTURE_NAME.

    Maybe the processing sequence is wrong: If you try to SET_SORT_CRITERIA before the fieldcatalog is filled, this error will come up.

    Check the sequence (may have been changed by SAP):

    1. build field catalog - you may use function LVC_FIELDCATALOG_MERGE

    2. SET_TABLE_FOR_FIRST_DISPLAY

    3. SET_SORT_CRITERIA

    Hope it helps,

    C.

    Add comment
    10|10000 characters needed characters exceeded