Two years ago, I made a database for one of our departments that tracks tasks that need to be done. Each task is given a priority between P1-P5 depending on how important it is. I use a query to filter out tasks that are being worked on or are done, and then produce a report that lists all the tasks that still need to be worked on. As a part of this report I sum up each priority and provide a count. I used the following equation to do that;
Code:
=Sum(IIf([Item_Query]![Priority]="P1",1,0))
Now I am doing a very similar thing for a different department and the only difference is that I named the query differently this time to avoid confusion. So my new equation is;
Code:
=Sum(IIf([Outstanding_Item]![Priority]="P1",1,0))
Other than the name nothing is different. Both queries contain the same information and are formatted the exact same way. When I run a report in the first database it spits out the correct count, but when I run it in the new one it spits out #Error. Just for kicks I tried renaming the query, the equation automatically updated for the change but it still spits out #Error. I am not sure what is going wrong, can anyone shed some light on this?