Forum Discussion
John_Chellew954
Apr 01, 2023Copper Contributor
Adding numbers created by the IF function in a row
I am using Excel 2019 and am setting up a golf scorecard to tabulate points for the Stableford system. I have gotten the formula to work by nesting the conditions but I can't add up the numbers in t...
- Apr 02, 2023
Yes, SUM() ignores any texts and calculates only numbers. It shall be
=IF(E7=1,6, IF(E7=2,4,...
instead of
=IF(E7=1,"6", IF(E7=2,"4",...
assuming the rest is correct.
John_Chellew954
Apr 02, 2023Copper Contributor
=IF(E7=1,"6", IF(E7=2,"4",IF(E7=3,"2",IF(E7=4,"1",IF(E7>4,"0"))))) for a par 3.
=IF(F7=1,"6", IF(F7=2,"6",IF(F7=3,"4",IF(F7=4,"2",IF(F7=5,"1",IF(F7>5,"0")))))) for a par 4.
=IF(D7=1,"6", IF(D7=2,"6",IF(D7=3,"6",IF(D7=4,"4",IF(D7=5,"2",IF(D7=6,"1",IF(D7>6,"0"))))))) for a par 5.
This translates into eagle or better = 6 points. Birdie =4 points. Par=2 points. Bogey=1 point. Double Bogey or more= 0 points.
My formulas work but when I use the SUM function to add the numbers for holes 1-9 or 10-18 on the row it comes up zero. It is like the function is not seeing the data in those cells as numbers.
=IF(F7=1,"6", IF(F7=2,"6",IF(F7=3,"4",IF(F7=4,"2",IF(F7=5,"1",IF(F7>5,"0")))))) for a par 4.
=IF(D7=1,"6", IF(D7=2,"6",IF(D7=3,"6",IF(D7=4,"4",IF(D7=5,"2",IF(D7=6,"1",IF(D7>6,"0"))))))) for a par 5.
This translates into eagle or better = 6 points. Birdie =4 points. Par=2 points. Bogey=1 point. Double Bogey or more= 0 points.
My formulas work but when I use the SUM function to add the numbers for holes 1-9 or 10-18 on the row it comes up zero. It is like the function is not seeing the data in those cells as numbers.
SergeiBaklan
Apr 02, 2023Diamond Contributor
Yes, SUM() ignores any texts and calculates only numbers. It shall be
=IF(E7=1,6, IF(E7=2,4,...
instead of
=IF(E7=1,"6", IF(E7=2,"4",...
assuming the rest is correct.
- John_Chellew954Apr 02, 2023Copper ContributorThank you Sergei! As simple as getting rid of the quotation marks. It works like a charm now!!
- SergeiBaklanApr 02, 2023Diamond Contributor
John_Chellew954 , you are welcome, glad to help