Sum Left Side & Right Side Numbers

  • Thread starter Thread starter Rob
  • Start date Start date
R

Rob

I'm hoping someone can help with this.

I'm trying to sum all the numbers on the left of a '/' and the the numbers
on the right of the same.

Example:
22/55
0/7
1/125
216/0

I trying to find a way to make the sumproduct provide the result of...
239/187.

So far for the right side I have...

=SUMPRODUCT(--(MID(R2:R4,FIND("/",R2:R4,1)+1,3)))

.... But I can't seem to get the Left side to work.


Thanks In Advance.
Rob
 
Assuming *every cell* contains the slash ( / )...

=SUMPRODUCT(--(LEFT(R2:R5,FIND("/",R2:R5)-1)))&"/"&SUMPRODUCT(--(MID(R2:R5,FIND("/",R2:R5)+1,3)))
 
=SUMPRODUCT(--LEFT(R1:R4,FIND("/",R1:R4)-1)) & "/" &
SUMPRODUCT(--(MID(R1:R4,FIND("/",R1:R4,1)+1,3)))
 
Hello,

Another way with a formula array
(validate the formula with Ctrl+Shift+Enter instead with Enter)

SUM(TRUNC(SUBSTITUTE(R2:R5,"/","."))) & "/" & SUM( -- MID(R2:R5,
SEARCH("/",R2:R5)+1,99))
 
I'm hoping someone can help with this.

I'm trying to sum all the numbers on the left of a '/' and the the numbers
on the right of the same.

Example:
22/55
0/7
1/125
216/0

I trying to find a way to make the sumproduct provide the result of...
239/187.

So far for the right side I have...

=SUMPRODUCT(--(MID(R2:R4,FIND("/",R2:R4,1)+1,3)))

... But I can't seem to get the Left side to work.


Thanks In Advance.
Rob


=SUMPRODUCT(--LEFT(rng,FIND("/",rng)-1))&"/" &
SUMPRODUCT(--MID(rng,FIND("/",rng)+1,99))

Be aware that this formula type (using FIND) will only work if
All the entries are text
All the entries contain a "/"

--ron
 
Back
Top