You should be able to check the number of records in the output file via the Count(*) function to see whether to print that message, or possibly a pre-select using that same function to see if there are any records which meet your criteria – but as far as how to actually print that message, I am not aware of a way to do that either with QM or with Query/400. It does’t appear that either one supports conditional logic in the report options or allows adding a custom text message.
Here is a thought. Inside of your query do you have some type of description or message field that is being filled from one of hte physical file fields? If so then using a Case Statement you could place your
message in that field if you find that a specific field from each of the other files is null. For Example
When FILEA.FIELD1 is null and
FILEB.FIELD2 is null and etc. (More conditions)
then “NO RECORDS FOUND”