Show Industrial Fields

Situation: I'm doing a query with format=template. Within the template, I do and #if test to see if the found record meets the criteria for what I want to display. Right now, the template is purposely failing all records. Result: The template returns nothing. Problem: I want to do an #if-test on the result of the query on this page, but despite nothing being printed, these #if's fail: