1. Welcome to Chandoo.org Forums. Short message for you

    Hi Guest,

    Thanks for joining Chandoo.org forums. We are here to make you awesome in Excel. Before you post your first question, please read this short introduction guide. When posting or responding to questions please remember our values at Chandoo.org are: Humility, Passion, Fun, Awesomeness, Simplicity, Sharing Remember that we have people here for whom English is not there first language and we need to allow for this in our dealings.

  2. Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User


  3. When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

CSV file with non-blank empty cells

Discussion in 'Ask an Excel Question' started by ashillz, Nov 8, 2018.

  1. ashillz

    ashillz New Member

    Hi All:

    I have exported to .csv some data from a database that I am trying to gain some basic insights into (% of fields populated, for example). It appears that every cell with no value is formatted in a strange way that it does not register as a blank cell when using formulas like COUNTA(). I was curious if anyone had a suggestion on how to systematically correct these 'blank' cells. My current approach of filtering each column for blanks, selecting those blank cells and hitting 'Clear' is not feasible on a file with many columns.

    Please see the attached sample file that demonstrates the problem here. Thanks for the help!


    Attached Files:

  2. Chihiro

    Chihiro Excel Ninja

    Welcome to the forum.

    Use COUNTIF() instead of COUNTA().

    Ex: In K8

    ? is any text (not numbers), * as wild card.

    So counting only cells with at least one character.
  3. ashillz

    ashillz New Member

    The approach mentioned by Chihiro seems to work on all fields in the sample file, with the exception of 'Id'. Is there a slight modification to this approach that will support number, text, and date values?
  4. John Jairo V

    John Jairo V Well-Known Member

    Hi, to both!

    You could try:
    [K5] : =SUM(COUNTIF(INDEX(B$5:F$30,,ROWS(K$5:K5)),{"?*";">0"}))

    And drag it down. Blessings!
    Chihiro likes this.
  5. Chihiro

    Chihiro Excel Ninja

    Though I'd recommend John's method. Another method is to add COUNTIF(Range,">0") to the formula.

Share This Page