Ignore Blanks with this formula

Agbarker

New Member
Joined
May 17, 2021
Messages
14
Office Version
  1. 365
Platform
  1. Windows
I am banging my head against a brick wall, but i cant for the life of me work out a way to ignore blanks and only take a number as an answer

=SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85='Group Stage Results'!B5)*('Group Stage Fixtures'!$C$50:$C$85>'Group Stage Fixtures'!$E$50:$E$85))

its this bit which is blank = Group Stage Fixtures'!$C$50:$C$85>'Group Stage Fixtures'!$E$50:$E$85))

if the cells are blank just return 0

any help would be highly appreciated on this

Many thanks
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Welcome to the MrExcel forum!

Try:

=SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85='Group Stage Results'!B5)*('Group Stage Fixtures'!$C$50:$C$85+0>'Group Stage Fixtures'!$E$50:$E$85+0))

I wasn't sure which of the two ranges has the blanks so I put the +0 in both, but that may not be necessary. If you have other non-numeric data in that range, that could pose another problem.
 
Upvote 0
Welcome to the MrExcel forum!

Try:

=SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85='Group Stage Results'!B5)*('Group Stage Fixtures'!$C$50:$C$85+0>'Group Stage Fixtures'!$E$50:$E$85+0))

I wasn't sure which of the two ranges has the blanks so I put the +0 in both, but that may not be necessary. If you have other non-numeric data in that range, that could pose another problem.
Hi Eric

Thanks for your reply unfortunately that has not solved it. I am going to upload the spreadsheet so you can see what i am doing.
 
Upvote 0
Ok so i cant upload the sheet but, here are some images

Fixtures image is where i am inputting the scores

then the group tables is where the formulas are

the formulas are as follows for the home stats in the middle

Home win = =SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85='Group Stage Results'!B5)*('Group Stage Fixtures'!$C$50:$C$85>'Group Stage Fixtures'!$E$50:$E$85))
Home Draw = =SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85=B5)*('Group Stage Fixtures'!$C$50:$C$85='Group Stage Fixtures'!$E$50:$E$85))
Home Loss = =SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85='Group Stage Results'!B5)*('Group Stage Fixtures'!$C$50:$C$85<'Group Stage Fixtures'!$E$50:$E$85))

I a having issues with the middle one as it is counting blank cells as a draw

Any ideas would be great, happy to keep playing around with it

Many thanks
 

Attachments

  • Excel Fixtures.PNG
    Excel Fixtures.PNG
    61.1 KB · Views: 7
  • Excel Group Table.PNG
    Excel Group Table.PNG
    38.3 KB · Views: 7
Upvote 0
Maybe:

Excel Formula:
=SUMPRODUCT(('Group Stage Fixtures'!$B$50:$B$85=B5)*('Group Stage Fixtures'!$C$50:$C$85='Group Stage Fixtures'!$E$50:$E$85)*('Group Stage Fixtures'!$C$50:$C$85<>""))
 
Upvote 0
Solution

Forum statistics

Threads
1,214,614
Messages
6,120,519
Members
448,968
Latest member
Ajax40

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top