Query does not count all records

C

Chris

I know I am new at this but seriously, I have a table that has 105,592
records in it. I build a query that works fine until I add the total row in.
Once the total is added and right now I just have it at Group then I end up
missing 1500 records or so from the main data.
Is this because of the Null value?

Thanks,
 
D

Dale Fye

Chris,

Most likely. If you are doing a count to get the number of records,
recommend you do COUNT(*) rather than Count([FieldName]). If you use a field
name, it will not count the NULL values.
 
M

Marshall Barton

Chris said:
I know I am new at this but seriously, I have a table that has 105,592
records in it. I build a query that works fine until I add the total row in.
Once the total is added and right now I just have it at Group then I end up
missing 1500 records or so from the main data.
Is this because of the Null value?


Most likely that because a Totals query with nothing but
Group By in the totals row doesn't so anything except
suppress duplicate records in the result dataset. If you
change a the entry to Count in a field that is supposed to
be unique and add a criteria of >1 for that field, you
should see just the records where that field is not unique.
 
C

Chris

Thanks, I will give that a try...

Marshall Barton said:
Most likely that because a Totals query with nothing but
Group By in the totals row doesn't so anything except
suppress duplicate records in the result dataset. If you
change a the entry to Count in a field that is supposed to
be unique and add a criteria of >1 for that field, you
should see just the records where that field is not unique.
 
Top