I need to fill in the column D using the information from column G (all in the first sheet) and the information from column A in the second sheet.
What needs to be returned to the column is the exact information found in the second sheet with the letter.
I have tried using vlookup with extract and other's but I always get N/A returned and im getting nervous.
Below are two screenshots of each sheet and at the bottom you will find an excel file uploaded with example data.
Excel file with example
You can do this with an array. Remember to enter the formula with Ctrl+shift+enter
=INDEX(ActiveCoupons!A2:A9,MATCH(G3,RIGHT(ActiveCoupons!A2:A9,LEN(ActiveCoupons!A2:A9)-1)*1,0))
In 'ActiveCoupons' put in G2 : =RIGHT(A2,LEN(A2)-1)*1
In 'ActiveCoupons' put in H2 : =A2
Expand the formulas to the rest of the columns G,H
In CouponRedemptionResults put in D2: =VLOOKUP(G2,ActiveCoupons!G:H,2,0)
Expand the formula to the rest of the columns D
Related
I'm trying to make a summary which list out all the matches and do a transpose of the table. I wrote a formula which works successfully. But, I come into another problem, which I find my formula cannot be dragged down and apply to all rows. Can anyone assist me in improving my formula?
Source:
Summary:
I would want to drag down the rows in "My summary" and the formula can do the columns+1 automatically. Appreciate for your help.
Here's my formula:
=IFERROR(INDEX(Sheet1!$F$9:$F$16, SMALL(IF(Sheet1!$H$9:$H$16="X",ROW(Sheet1!$H$9:$H$16)-ROW(Sheet1!H$9)+1),COLUMN(A1))),"")
In your screenshot it's difficult to tell which rows the data lives in. The following formula has been entered into Sheet2, cell B2 and copied down.
=IFERROR(TRANSPOSE(FILTER(Sheet1!$F$9:$F$16,INDEX(Sheet1!$H$9:$K$16,1,ROW(A1)):INDEX(Sheet1!$H$9:$K$16,8,ROW(A1))="x")),"")
Source screenshot Sheet1
Result screenshot Sheet 2
This approach uses Excel's Dynamic Array functionality, available only in Excel license with Office 365. The formula is only in column 2. It automatically spills its results into the neighboring columns as required.
edit after comment
If you don't have Office 365, you can use a variant of your formula, where the Index is replaced by and Index():Index() technique. The first Index pulls the first row, the second Index pulls the last row and the two results are combined with the range operator : that combines the two results into a range.
=IFERROR(INDEX(Sheet1!$F$9:$F$16,
SMALL(IF(INDEX(Sheet1!$H$9:$K$16,1,ROW(A1)):
INDEX(Sheet1!$H$9:$K$16,8,ROW(A1))="X",
ROW($A$9:$A$16)-ROW(A$9)+1),COLUMN(A1))),"")
Start in the first result cell (B2 in my screenshot) and use Ctrl+Shift+Enter to confirm, since it is an array formula. Then copy across and down.
Note: screenshot results are different, since I recreated the sample from scratch and the source data is different.
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.
Is there a way to copy filtered list to another sheet using formula? I know how to copy visible cells, but I need to do it by formula.
just change A:A to whatever column your list is in and change the destination :)
Sheet1.range("A:A").SpecialCells(xlCellTypeVisible).Copy Destination:=Sheet2.Range("A1")
ps next time just google excel vba whatever you're looking for, it brought me here
https://stackoverflow.com/a/13956899/6868389
Say we have data in columns A and B that we are going to filter. In C2 enter:
=IF(SUBTOTAL(3,B2:B2)=0,MIN($C$1:C1)-1,SUBTOTAL(3,$B$2:$B2))
and copy down:
If we filter column B for the 2' s, we see:
Even filtered, column C still shows the simple sequential sequence. We can now easily retrieve data from the visible rows using MATCH() and INDEX():
In Sheet2 cell A1 enter:
=IFERROR(INDEX(Sheet1!A$1:A$22,MATCH(ROWS($1:1),Sheet1!C$1:C$22,0)),"")
and copy down:
We can retrieve info from other columns in the same fashion.
Another good place to post non-programming questions like this is:
superuser
Ex.
column A is a formula that outputs an 8 digit ID from a prior delimited calculation. I want to vlookup that ID to a separate set of data, but it is not finding the ID when the lookup value is part of a formula.
Is there a way to paste the formula result as a value in column b?
I have a list of 3000+ IDs, so using the F2, F9 trick won't work, since I would have to do that cell by cell.
Would prefer not to use VBA, but if that is the only way, can someone help simplify that process (new to using VBA)
If you have data in column A based on a left function of a bunch of numbers, and just want that result in column B, all you have to do is put:
=Value(ColRow)
in Column B. Then you can look up the value in Column B via VLookUp.
I am an avid Excel user and personally tested this solution. Though it appears #Scott beat me to it in the comment section.
I'm having difficulty getting my vlookup formula to pull url data from another sheet (Sheet 2) and insert added information to the url based on what is in its A cell on Sheet 1.
For example,
The vlookup formula =VLOOKUP(B2,Sheet2!A:B,2,FALSE) will check to see if B2 (Sheet 1) matches with Data on Sheet 2. It will then return the data it has matched:
=HYPERLINK("http://www.dpd.co.uk/tracking/quicktrack.do?search.consignmentNumber="&Sheet1!A2&"&search.searchType=16&search.javascriptValidated=0&appmode=guest")
I then want the url link to insert whatever text is in the Sheet 1 A cell.
The formula I have used does this nicely, but I want the formula to correspond down the workbook for whatever is in cell A, not just A1 i.e. Sheet 1 A3,Sheet 1 A4....
How can I do this?
Thanks
I'm not sure if I completely understand what you are asking but allow me to share my experience with what I believe was a similar problem.
My solution was an offset/match formula. I used a formula similar to:
=OFFSET($A$1,(MATCH(B$2,'Sheet2'!$A:$B,0)+$A1),0)
And had a list of values in column A that corresponded to the distance that row was to the object cell I wanted to keep constant. Then I used autofill to fill column a down the sheet as far as I filled the formula. This way offset refrence changed on each row and I was still able to auto fill.
I hope that helps