473,466 Members | 1,430 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

I need to total Yes/No fields

2 New Member
I have a form with 20 yes/no fields. If the user leaves a field blank (that is, answers no), I need to include this in a total. I have a field called "Rating" that is the total # of "No's" for that record.
Aug 26 '10 #1
1 1043
NeoPa
32,556 Recognized Expert Moderator MVP
Try something like :
Expand|Select|Wrap|Line Numbers
  1. SELECT YN1
  2.      , YN2
  3.      , YN3
  4.      , ...
  5.      , YN20
  6.      , IIf([YN1], 1,0) +
  7.        IIf([YN2], 1,0) +
  8.        ...
  9.        IIf([YN20], 1,0) AS Ys
  10. FROM   ...
Welcome to Bytes!
Aug 26 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Mosher | last post by:
Hi all, I am looking for some event handler auto-calc help on a form that takes user input through text fields and dropdown menus. I would like some of the text fields to be auto populated when...
3
by: JC Mugs | last post by:
I have a report coming from a query that I need to print. Question: I want to have fields print or not print on a value of one of the fields... Like this- IF Doz2 >0 then Print Doz2 ...
2
by: Darryl Kerkeslager | last post by:
As the subject above hopefully makes clear, I want to do several reports, "with lots of fields not otherwise in database". These reports also have variable-length text. I have defined the...
1
by: Dan | last post by:
I am linking two queries in Access. One has data in several fields such as: Name, Year, Amount, CumTotal1, CumTotal2 where the cumulative total fields are two subqueries generating cumulative...
3
by: JDiamond | last post by:
Hi, I have a table called Hosts. The Hosts table contains the following fields: Each field represents a step in the project. The tech that completes each step initials the respective...
2
by: fstenoughsnoopy | last post by:
I have a customer order database and I need to pull a customers information, ie first name, last name, address, city, state, zip, phone, etc, into the oder table. i don't know how to go about...
2
by: zhang | last post by:
Hi, I try to protect some fields from editing by user after the records of table showing in datagrid using VB 6.0. How can I do? Please help Zhang
2
by: Jana | last post by:
Using Access 97. Background: I have a main report called rptTrustHeader with a subreport rptTrustDetails in the Details section of the main report. The main report is grouped by MasterClientID. ...
3
by: voroojak | last post by:
hi I have a such abig problem. i have to disable the shortcut keys (table, query, report, .....) except form. the user should just be able to open form and all other the shortcut should be disable....
1
by: erics44 | last post by:
Hi I have a Matrix in a report and i want the total column to sum a different field that is in the column group, is there any way of doing this? here is an example of my matrix ...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.