[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Help with a calculation in a report or query ms access 2003

Posted on 2012-08-22
5
Medium Priority
?
323 Views
Last Modified: 2012-08-22
I'm sure this is an easy one but being a novice here has me stumped. I created a simple form based off of one table (see attached). The form has to drop downs. One called area auditied the other status. The status drop down has three choices audits completed, safe audits, and unsafe audits. I created a calcuation query that will count the number of choices from the status drop down. So for example if I have three records and out of two of those records unsafe audits were chosen it shows a total of 2 in the query. I then created a report from my calculation query. So far very simple. Here is my issue that I cannot figure out. What I need to happen is have a calculation that gives me a percentage of unsafe audits. So my calculation should be unsafe audits / completed audits = the percentage. Can someone look at my attachement and fill in the blanks for me? Or if my query itself is not efficient you are more than welcome to change it. Hopefully I made sense
0
Comment
Question by:tmaususer
  • 3
  • 2
5 Comments
 

Author Comment

by:tmaususer
ID: 38320294
Sorry. Here is the attachment.
Safety.mdb
0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 800 total points
ID: 38321042
Two brute force techniques
Safety.mdb
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 38321062
I only did the calc in the query to show that it could be done.
Using the query may not be optimal, because it shows the same value for all records...
(You could probably get crazy and use a UNION query or some other technique though, to get a better output)

I prefer the "from table data" technique
You can use the same technique on your form.

There are a few other ways that this might be done more "elegantly", so let's see what the other experts post

;-)

JeffCoachman
0
 

Author Closing Comment

by:tmaususer
ID: 38321264
No way I would have figured this one out. Thank you very much
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 38321852
glad I could help.
;-)

Jeff
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Microsoft Access has a limit of 255 columns in a single table; SQL Server allows tables with over 255 columns, but reading that data is not necessarily simple.  The final solution for this task involved creating a custom text parser and then reading…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question