简体   繁体   中英

Complicated counting in excel

I have the following columns in Excel

    a    b    c
 1 SUM  1st  2nd
 2 0    2/2  2/4
 3 0    1/1  3/4

b2 is defined as "=CONCATENATE(TRUNC(2);"/";TEXT(('Other sheet'!B2);0))" and similar to b3,c2,c3.

Column |SUM| should count sum from |1st| to |2nd| but only the first numbers before "/".

for example: b2+c3+... = 2+2+... = 4+... so a2=4+...

any ideas how to do that? :)

You can use the 'left' function

Use it like this

A2=left(B2;1)+left(C2;1)

使用以下公式,使用功能移位+ ctrl +输入:

=SUM(TRUNC(MID(B2:C2,1,SEARCH("/",B2:C2,1)-1)))

Here's a simple way to do it

=SUMPRODUCT(INT(SUBSTITUTE(B2:C2,"/",".")))

Extend your range as far as you need by changing B2:C2 to B2:X2 , for example.


I think this might work for your system.

 =SUMA.ILOCZYNÓW(ZAOKR.DO.CAŁK(PODSTAW(B2:C2;"/";"."))) 

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM