Yet another Access Query Question. Similar to my
other question, but even more frustrating. I need to craft a query that will tally values across many fields and entries.
Ok, So I have this table that has ALOT of fields, basically repeating, but not really. The user has to look at 40 different Criteria and report its state (Ok, NG, NA) and if they are NG they need to choose one of several "failure modes" that vary for each question. My table is built like this:
OpStdA | OpStdB | MasterLabelA | MasterLabelB |etc,etc
Where the A fields hold the OK/NG/NA data, and the B Fields hold the reason why it faid if A was NG
Thanks to the help I recieved on my last question I can now run a query that will pull out all of the "NG" audits, but now I need to take that information and extract even further information from it.
As I said before, each question has different failure modes. So OpStdB may have one of the following
Not Posted
Missing Pages
Unreadable
And the next one, MasterLabelB will have one of these
Missing Label
Wrong Label
Now some may have ones that repeat (Such as 'Op not following standards' which could apply to several different criteria).
I need to write a query that will count each Value for me. I want to know that between all of the results there were 120 Not posted, 10 Missing Pages and 40 Wrong labels.
I know my access-fu is weak, and I should have made this a relational Database originally. But it is what it is, and I just want to make it work at this point rather than remake everything from the ground up.
So hive mind, How do I make access count values to suit my needs.
go to new query, add your table(s) and then select 'crosstab query' from the query types.
so opstdb might be your row value, masterlabelb your column value, and then select any other field that always has data (at my current job, I use the 'state' field in the address portion of the record, or sometimes I create a new field in a table called 'count' and then populate it with 1's)
if your data is complex, or in multiple tables, it might be easier to build a seperate table for the basis for your crosstab.
good luck.
posted by lester at 9:28 AM on June 21, 2006