Skip to Content
0
Former Member
Mar 31, 2006 at 08:03 AM

delete row if field is initial.

1046 Views

Hello,

What I want to do is to delete the whole row if a specific field is empty. If it helps this is an ALV_GRID report

I have seen that there are a couple of topics about this but I haven't been able to solv it. My attempts are in bold.

wa_rec-sek_norm_sal = wa_rec-norm_sal - wa_rec-bet01.

<b>if wa_rec-sek_norm_sal is initial.

delete wa_rec.</b>

endif.

append wa_rec to lt_rec.

<b>loop at lt_rec.

if lt_rec-sek_norm_sal is initial.

delete lt_rec.

endif.

endloop.</b>

Error from <b>first</b> attempt:

"WA_REC" is not an internal table - the "OCCURS n" specification is missing"

Error from <b>second</b> attempt:

The internal table "LT_REC" has no Header line - explicit specification of an output area with "INTO wa" or "ASSIGNING <fs>" is required.

Thank you all.

Best Regards Claes