Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel-Have a formula skip null values 1

Status
Not open for further replies.

FrauW

MIS
Jul 24, 2003
126
US
Hi experts... I created a formula to convert dates into Quarters because we're trying to avoid buying the DigB add-in. Thing is I'm not sure how to have this formula skip the fields that are blank. Basically I want the formula to read the entire column, pick out dates (which it will read in the serial format) and then convert these to quarters. So for Jan-06 through Dec-06 my formula is:
=IF(A:A<=38777,"Q1",IF(AND(A:A>38777,A:A<38899),"Q2",IF(AND(A:A>38869,A:A<38991),"Q3",IF(A:A>=38991,"Q4",""))))

It works great except for the fact that it's populating blank fields where there is no entry. HELP! :)
 
=IF(AND(A:A>38717,A:A<38777,"Q1",IF(AND(A:A>38777,A:A<38899),"Q2",IF(AND(A:A>38869,A:A<38991),"Q3",IF(A:A>=38991,"Q4",""))))


Member AAA - Abolish Abused Abbreviations
 
I would suggest following changes:

=IF(AND(A:A>38717,A:A<38777,"Q1",IF(AND(A:A>38776,A:A<38899),"Q2",IF(AND(A:A>38898,A:A<38991),"Q3",IF(A:A>=38990,"Q4",""))))


Member AAA - Abolish Abused Abbreviations
 
I have been thinking (a very dangerous thing), but wouldn't this work better for you?

=IF(A2="","",INT((MONTH(A4)-1)/3+1))

Member AAA - Abolish Abused Abbreviations
 
Sorry changed one cell but not the other. In my spreadhseet I was on cell A4

=IF(A2="","",INT((MONTH(A2)-1)/3+1))

Member AAA - Abolish Abused Abbreviations
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top