https://blog.faq400.com/en/db2-for-i/sql-en/get-diagnostics-db2-number-rows-en/
SQL: How many rows in my select statement?