473,387 Members | 1,582 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

NULLS Affecting Embedded Query Calculations

I'm sure this has something to do with NULLS, but I just can't get my
head around this behaviour. More importantly, I can't SOLVE this
behaviour, and until I do I can't have any confidence in my data!

- Specs: Access 2007, Windows XP, data in linked (mySQL) table.

- I have a text (varchar) field called [HighestEducation] that
contains NULL values.

- I have a calculated field [HighestEducation_Valid] to check the
quality of the contents of the text field. The formula is:

IIf(IsNull([HighestEducation]),"No
Response",IIf([HighestEducation]="","Invalid/Incomplete","Complete"))

In my query results (datasheet), the contents of
[HighestEducation_Valid] are:
--- 287 COMPLETE
--- 1 INVALID/INCOMPLETE
--- 301 NO RESPONSE.

My problem is that when I use this query in a *subsequent* query (e.g.
SELECT [HighestEducation_Valid], COUNT(myID) FROM myQuery GROUP BY
[HighestEducation_Valid];), I get:
--- 287 COMPLETE
--- 302 INVALID/INCOMPLETE.

(Other notes:
- I've also tried IIf([HighestEducation] Is Null... but the behaviour
was unchanged.
- This is all happening in vanilla queries, no VBA involved at all.)

Any ideas?

Many thanks,
- Linda Patterson
- Dunedin, New Zealand

Jun 19 '07 #1
0 1111

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Alex | last post by:
Hi folks, I'm doing calculations based on data in a table, but the data has some zeros in the field I'm dividing by. I'm trying to write a script to replace any field with 0 or null with 1, but...
2
by: Steve Walker | last post by:
Hi all. I've been tasked with "speeding up" a mid-sized production system. It is riddled with nulls... "IsNull" all over the procs, etc. Is it worth it to get rid of the nulls and not allow...
2
by: Steve | last post by:
I am trying to evaluate the latest occurence of a date which will go in the field titled eligibility date. Table is set up as follows and am using update query to update the eligibility date to...
0
by: Erwin | last post by:
I am writing VBA code in a report code module. I need to make calculations that display on the report based on information on a query. What is the syntax for that? The logic is below. if...
1
by: PST | last post by:
Here's a problem I'm trying to deal with: I'm working on a Frontpage 2000 website for a boat handicapping system, built in Access 97. What I'm trying to accomplish is: The user enters a...
0
by: LesM | last post by:
This is a change of behaviour between Access 2000 SP3 and Access 2002 SP3. I have Progress table that is linked via ODBC into Access using OpenLink Lite for Progress 9.0b. For over a year, using...
13
by: Angus | last post by:
Hello I have a stream of bytes - unsigned char*. But the 'string' may contain embedded nulls. So not like a traditional c string terminated with a null. I need to calculate the length of...
6
by: Cliff72 | last post by:
I need to fill in the nulls in the batch field the value from the record immediately preceding the null one ie replace the nulls with the preceding value until I hit a record with a value in...
3
by: localharbor | last post by:
I am a newbie to c++, so maybe this one's too easy, tho apparently not for me: 1. I am using MS Visual Studio. 2. I have a std::string variable. 3. Its value might contain embedded null...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.