Application Development 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: 

ALV Filter Not Working

former_member422932
Participant
0 Kudos
1,842

When trying to add a filter to an existing layout, the filter disappears. Also, if I try to create a new layout on the field I want to filter on, the program short dumps when trying to save the filter complaining about "ASSERTION FAILED". I am not sure what is wrong. My internal table is the following.

TYPES: BEGIN OF GS_DELIVERY.
TYPES: CHECKBOX TYPE C.
INCLUDE STRUCTURE ZDP_DELV_INF.
TYPES: T_COLOR TYPE LVC_T_SCOL,
ORD_NUM TYPE VBELN_VA,
ORD_TYPE TYPE AUART,
QDATU TYPE LTAP_QDATU,
QZEIT TYPE LTAP_QZEIT.
TYPES: END OF GS_DELIVERY.

The filter I am trying to set is on ORD_TYPE. I have two containers to set header and line item data using method SET_TABLE_FOR_FIRST_DISPLAY. I have look at a number of posts, but not sure what I am doing wrong. Can anyone provide some insight as to what I am doing wrong, and how to resolve my issue.

9 REPLIES 9

jens_michaelsen
Participant
1,717

You are unfortunately too sparse with information. None of us can see clairvoyantly. Take a look at the short dump description and maybe the error will be clear.

raymond_giuseppi
Active Contributor
1,717

Perform The Consistency Check - ALV Grid Control as something should be wrong with your layout / field catalog, correct reported errors.

former_member422932
Participant
0 Kudos
1,717

I appear to have gotten passed my short dump issue. However, when I try to add the field ORD_TYPE(sales order type) as a filter to an existing layout after saving the layout and overriding the current layout, my field is removed from the filter screen. I would be happy to send more screen shots, just not sure what I am missing.

0 Kudos
1,717

I am still getting a dump, but not sure why when trying to perform a filter. Can you provide any help on the following.

The current application program has detected a situation with the

ASSERT statement that should not occur.

The reason for this runtime error was one of the following:

- For the checkpoint group specified with the ASSERT statement, the

activation mode is "abort".

- A system variant has been used to set the activation mode to "abort"

globally for all checkpoint groups in this system.

- The activation mode is set to "abort" at program level.

- The ASSERT statement is not assigned to any checkpoint groups.

The following chec

If the FIELDS addi

the content of the

(not used)

(not used)

(not used)

(not used)

(not used)

(not used)

(not used)

" (not used) "

If the error occurs in one of your own ABAP programs or an SAP program

that you have modified, try to correct the error yourself.

If the error occurs in a non-modfied SAP program, you might be able to

find a solution in the SAP Notes system. If you have access to the SAP

Notes system, check there first using the following keywords:

"ASSERTION_FAILED"

"CL_SALV_BS_FILTER=============CP" bzw. CL_SALV_BS_FILTER=============CM00C

"DO_STRATEGY_DYNAMIC_WHERE"

If you cannot solve the problem yourself, please send the following

information to SAP:

0 Kudos
1,717

Please add all this information to your question, not as an answer.

(via Actions > Edit)

arviobj
Explorer
0 Kudos
1,717

Hello, this thread recommends using upper case and lower case combination when preparing the fieldcatalog. Also, if you're not using upper case and lower case combination you should pass the filter value with pattern (*) in the selection criteria.

former_member422932
Participant
0 Kudos
1,717

Could part of my problem we with how the internal table GS_DELIVERY I provided is defined, ZDP_DELV_INF is a table of data? I am at a lose as to the problem, because after I run the report I can filter on the column order type(ORD_TYPE) and exclude data, but when I try to save the filtered data as a layout it is dumping on method DO_STRATEGY_DYNAMIC_WHERE. Here is the code, and when trying to save the layout it hitys the catch statement.

try.
loop at <lt_outtab> transporting no fields where (l_fs_complete).
ls_row-row_index = sy-tabix.
insert ls_row into table t_filter_index_inside.
endloop.
catch cx_sy_itab_dyn_loop into lr_x.
assert 1 = 2.

endtry.

Sandra_Rossi
Active Contributor
0 Kudos
1,717

You are not answering the questions of experts (Jens, Raymond), other experts are waiting for these answers to help. It's currently impossible to help you based on the information you have posted.

Moreover, the best way to ask a question about programming is to provide the steps to reproduce, including a minimal reproducible example.

former_member422932
Participant
0 Kudos
1,717

I figured out the problem, and it had to deal with the new fields missing the field TBANAME in the field catalog. Thank you for all of the feedback, sometimes issues require another pair of eyes, or stepping away and then revisiting the issue