Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

condition to check if field has records(FOR ALL ENTRIES)

Hello experts,

I am using FOR ALL ENTRIES in my select statement. Now, how can I check if the field that I am comparing to has

any records? So if does not have any, it would not do my select. Below is my select statement. Again, thank you guys and have a nice day!

SELECT equnr anlnr shtxt FROM itob

INTO TABLE it_itob2


WHERE equnr = it_equz-hequi.

**I need to know if it_equz-hequi has any records so if it does, it will do the select statement above else, don't.

Former Member
Not what you were looking for? View more on this topic or Ask a question