Solved

Access - Totals Query  - Include Count for Blank Cells

Posted on 2009-04-02
8
459 Views
Last Modified: 2012-05-06
In the attached Excel workbook, please find an example of a Pivot Table that was created, where cells that were blank are still counted as a value (i.e. I want to know how many blank cells the column contained).

I would like to reproduce the Pivot Table results on the sheet "Summary Count" that is based off of the data on sheet "Pivot Empty Sample."

Thanks
Sample-Pivot-Empty.xls
0
Comment
Question by:tahirih
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
8 Comments
 
LVL 44

Expert Comment

by:GRayL
ID: 24053549
Having filled the blanks with ="", the cells are no longer blank - they are text.  Find an empty cell, A623 for example and in B623 type =IsText(A623) returns True.  Make sure you are counting the right thing.
0
 

Author Comment

by:tahirih
ID: 24053636
How can I implement this in an Access Query?

Thanks
0
 
LVL 44

Expert Comment

by:GRayL
ID: 24053713
You have imported the file into Access?  When you go to record 623, does FSC look empty?  If so run this query:

SELECT Count(FSC) FROM myTable WHERE FSC=""
0
Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

 
LVL 44

Expert Comment

by:GRayL
ID: 24053737
I guess I have to ask - Why is this question in the Access Zone?
0
 

Author Comment

by:tahirih
ID: 24053800
Please review the Pivot Table results. I want to get a resulting Access table that looks just like this (without the Grand Total at the bottom).

Here are the steps I need to clarify:

1. The Excel table I did format, to be able to create the Pivot Table you see
2. Please assume that the Access table will not have any prior formatting to blank cells (the Excel table did not either - I included ="" to create the Pivot Table).
3. Similar to the ="", I would like to have a similar coding system in Acces

Therefore, I have placed the question in the Access zone. Hope this made sense.
0
 
LVL 44

Accepted Solution

by:
GRayL earned 500 total points
ID: 24054021
Import the Pivot Empty_Sample sheet using the Import wizard.  Then run this query:

SELECT fsc, Count(Nz(fsc,""))
FROM [Pivot Empty_Sample] GROUP BY fsc ORDER BY fsc;

0
 

Author Closing Comment

by:tahirih
ID: 31565929
Just what I have been looking for.

Thanks!
0
 
LVL 44

Expert Comment

by:GRayL
ID: 24054335
Thanks, glad to help.
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

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

As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
This post looks at MongoDB and MySQL, and covers high-level MongoDB strengths, weaknesses, features, and uses from the perspective of an SQL user.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

719 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