Filter name in report

Atthe

Member
Local time
Today, 08:34
Joined
Oct 26, 2021
Messages
57
Good Morning All,

I have some filters in a form that are chosen before the report in created with a button, For clarification to the end users means the filtered field does not directly appear in the 'Detail' section of the report I created a text box with the control source set as the filtered field (Tag) which is in the header section. This has worked fine however I now have a query that filters on two criteria "Tooling" or "Inspection".

The issue I now have is that only one of my criteria's is returned to the textbox, what is the best was to return both criteria or one criteria? (Depending on the selected filter?

Thanks
 
This has worked fine however I now have a query that filters on two criteria "Tooling" or "Inspection".
Can we see the image of the query design or the syntax of the query(in sql view)?
 

Attachments

  • filter.PNG
    filter.PNG
    3.6 KB · Views: 307
The Or operator will check if at least one of the conditions is true, then will return the query based on it.

It is possible that the other criteria not been returned is not true.
 
Try the IN operator

Code:
SELECT * FROM tblTools
WHERE
tblTools.Tag IN("Inspection","Tooling")
 
If you are building the where clause in a form, build the text at that time. Then the report can get it from the form:
=Forms!myform!myfilter
 

Users who are viewing this thread

Back
Top Bottom