So my sheet looks like this:
I need to sum the values based on text in the products column.
Can someone explain to me how this is done without using VBA?
Enter the following formula in Cell B2
=SUM(IF(ISNUMBER(FIND(","& E$1:E$5&",",","&A2&",")),F$1:F$5))
This is an array formula so commit it by pressing Ctrl+Shift+Enter. Drag/Copy down as required. See image for reference.
Got this from here.
Related
My Data:
I am trying to replicate the answer/formula from Column H. This is an array formula, so I committed it with Ctrl+Shift+Enter (C+S+E going forward).
My formula (in H2) is:
=MAX(IF(Sheet1!$X$3:$X$94=Sheet4!A2,Sheet1!$AI$3:$AI$94))
Columns I:L are different options I tried to replicate.
Column I: I highlighted the relevant cells, then put the above formula (from H2) in cell I2, and then used C+S+E. The result is 2 the entire way through.
Examining the differences between the formula between cells H5 and I5 shows that the reference "Sheet4!A2" is different.
In Column H, the cell reference is "Sheet4!A5", which is correct.
In I5, the reference is "Sheet4!A2, which is incorrect.
To get past this, I tried to write the formula in Column J, and drag it down, which resulted in all errors.
Columns K and L are instances where I tried typing in the formula, highlighting my range, and then pressing C+S+E, either by hand (Column K), or moving between sheets and highlighting relevant references (Column L). The same issue arose.
I even tried highlighting Column H, editing Cell H2, and the hit C+S+E. I got the same result as I did in Column I.
I looked at Excel Array Formula and Excel: Array Formula Calculates Once, but those suggestions did not help me in this instance.
Automatic calculation is on in my spreadsheet.
You need to understand that when you have selected more than one cell, enter a formula and confirm with CSE, it is totally different than having just one cell selected, enter the formula and CSE.
In your scenario, you want to select just one cell. Enter the formula, confirm with CSE, then copy the formula down. The references that are preceded with a $ sign will stay the same. The references without a $ sign will be adjusted when the formula is copied.
You may want to refresh you knowledge about relative and absolute reference, for example here
I have an excel sheet with the given date in Column A and B. I want to convert the same as shown on right side of the picture
If you wish to use formula approach, then please add this formula =IFERROR(INDEX($B$2:$B$14,SMALL(IF($D2=$A$2:$A$14,ROW($A$2:$A$14)-ROW($A$2)+1),COLUMN(A2))),"") in cell E2. When entering formula please use CTRL+SHIFT+ENTER combination, since this is array formula. After you confirmed formula, drag it across your area E2:H5.
Currently at my workplace, I am facing an issue of grouping items. As shown in the image, I need to group the first group of RIOs in a cabinet as 1 and the second group of RIOs in that same cabinet as 2. The process is the same for different cabinets.
Is there a way to get this done by using Excel formula? I don't mind creating extra columns for rough works. It should be noted though that the formula need to work in a table format.
Example:
Well, If I understood your problem correctly then following should help. (Using helper column)
In Cell C3 and Cell D3 write 1
Then in Cell C4 enter the following formula
=IF(B3=B4,C3,C3+1)
And in Cell D4 enter
=IF(C3=C4,IF(A3=A4,D3,D3+1),1)
drag/copy down both formulas as required. See image for reference.
Note : For this solution to work Category column should be sorted.
I have two columns of data in excel sheet- column A and column B. I want that the values which are in column a but not in column b, should appear column c. for example please look at this screen shoot-
http://imgur.com/a/qYmFF
THANK YOU VERY MUCH..
You can use this array formula in C2(it must be in C2 or the reference of $C$1:C1 must be changed to the cell directly above the first instance of this formula):
=IFERROR(INDEX($A$1:$A$10,MATCH(1,(COUNTIF($A$1:$A$10,$A$1:$A$10)<>COUNTIF($B$1:$B$6,$A$1:$A$10))*(COUNTIF($C$1:C1,$A$1:$A$9)<COUNTIF($A$1:$A$10,$A$1:$A$10)-COUNTIF($B$1:$B$6,$A$1:$A$10)),0)),"")
Being an array formula it must be confirmed with Ctrl-Shift-Enter instead of Enter when exiting edit mode. If done correctly then Excel will put {} around the formula.
Then copy/drag the formula down till you get blanks.
I am working on a personal budget sheet in excel, and it's formatted based on my pay dates, to provide more drilled-down information. I have attached an example of it below for reference.
I would like to put a formula into J2, J3, and J4 which will take the data in cells C9:C26 and H9:H16, match it to the date in cells D2:D4, then subtract the expenses in D9:D26 and I9:I16 from E2, E3, and E4.
As you can see, I have just individually summed the cells; however, I would like a formula to be able to adjust as I change the value in cells C9:C26 and H9:H16.
I have found that I can do it with ONE cell, but not multiple or a range. This is the formula I used, and I cannot find a way to make it apply to the entire range of cells: =IF(C14=D3,E3-D14)
I've also tried: =IF(C9:C25=D3,E3-D9:D25) -- I know this formula doesn't work and why. I cannot figure out how to get column C to correspond with column D.
The Budget Sheet
You just need to use SumIf().
In cell J2, put this formula: =SumIf($C$9:$C$25,$I2,$D$9:$D$25)+SumIf($H$9:$H$25,$I2,$I$9:$I$25) and drag down the three cells.
With that, you can add E2-[formula] to subtract all that from E2. Or of course, just do e2-J2 instead. I think that should do what you're looking for. If it's not quite it, let me know and I can tweak.
If you plan to have more than 1 criteria go with SUMIFS
Yes, with S