Subtotal and Sumiif Issue in excel - excel

On the below image, how to do sumiif and subtotal?

Try below formula
=SUBTOTAL(109,B1:B6)
=SUMPRODUCT(SUBTOTAL(109,OFFSET(B1,ROW(B1:B6)-ROW(B1),,1)),--(A1:A6 <> ""))

You can solve your problem by adding a helper column. Place this formula in C1 and copy it down to C6: =SUBTOTAL(109,B1).
Then in B7, use this formula: =SUMIFS($C$1:$C$6,$A$1:$A$6,"<>")

One way is by using another cell.

Related

How to add sequentials in a numbar using formula?

I need a Formula to use in my table, that will get me the following result
Please check this image
In B2 for example it is 1+2+3+4+5
In B3 As Another example it is 1+2+3+4+5+6
etc...
thank you
This is simple math:
=A2*(A2+1)/2
Try
Formula used in cell B2
=SUMPRODUCT(ROW(INDIRECT("1:"&$A2)))

formula to subtract pairs of cells - excel

I have a spreadsheet which I want to: E2=C3-C2, then E3=C5-C4, E4=C7-C6 etc for lots of cells:
So I am looking for a formula which I can drag down which minuses values in pairs rather than consecutively.
I tried SUM(OFFSET) but only added values, not minus.
Any help greatly appreciated!
If you must use a formula in E2, then try:
=INDEX(C:C,ROW()*2-1)-INDEX(C:C,ROW()*2-2)
Your idea of using OFFSET can be made to work. In E2 put
=OFFSET($C$1,2*ROW()-2,0)-OFFSET($C$1,2*ROW()-3,0)
and copy down.

Highlight duplicates that share the same date

I am trying to highlight duplicate addresses that share the same date.
I have tried these formulas in Conditional Formatting but they did not work.
=IF(SUMPRODUCT(--(A:A=A1),-(B:B=B1))=-1,"No Duplicate","Duplicate")
=COUNTIFS($A$1:$A$21,A1,$A$1:$A$21,"<>",$B$1:$B$21,B1,$B$1:$B$21,"<>")>1
If you could also explain what the formula is doing would be awesome.
Thanks a lot.
Use the 2nd formula but change $A$1 to $A$2, $B$1 to $B$2, A1 to $A1 and B1 to $B1.
=COUNTIFS($A$2:$A$21,$A2,$A$2:$A$21,"<>",$B$2:$B$21,$B2,$B$2:$B$21,"<>")>1
Another option:
=SUM(($A2=$A$2:$A$10)*($B2=$B$2:$B$10))-1

Autofill column excel

What is the formula to autofill (autoincrement) the No. column when pemesanan column are already filled? I use a google spreadsheet
Using cell B8 as an example to drag down:
=IF(LEN(C8)>0,1+B7,"")
As you serial no. starts from B5 cell then you can use below formula.
=IF(C5<>"",ROW()-4,"")
Done by myself.
I'm using =ARRAYFORMULA(condition;true_condition;false_condition)
in my case I'm using this formula =ARRAYFORMULA(if(C5:C="";"";ROW(B5:B)-4))

Drag down and change value of formula

I have this formula:
=IF(INDIRECT("summary!a2")="","",INDIRECT("summary!a2"))
.. this will retrieve the value of the a2 cell in the summary sheet.
What i want to know is what can i do on this formula to allow the value a2 to change to a3/a4/a5 etc.. when dragged down the sheet .
Can anyone give me a hint here?
Thanks
Try: =IF(INDIRECT("summary!a"&ROW(A2))="","",INDIRECT("summary!a"&ROW(A2))) - applicable for drag down)
If you use CELL function you can also drag down and across, e.g.
=INDIRECT("Sheet2!"&CELL("address",A1))

Resources