I want to separate Excel Cell Value With Specific Column.
Please, Check the screenshot.
I want to Separate all Date of Birth in one column, all age cell in Age Column. How Can I do it?
Automatically cell will move the specific column.
You can use this formula in cell F3
=CONCATENATE(IF(F$2="","",IFERROR(INDEX($B$3:$D$6001,ROW($A1),MATCH(F$2&"*",$B3:$D3,0)),"")),IF(F$1="","",IFERROR(INDEX($B$3:$D$6001,ROW($A1),MATCH(F$1&"*",$B3:$D3,0)),"")))
Put your partial search values in range F1:H2(1st row is used in case you have multiple search words for same column. Your data should start from cell A3.
I am assuming strings Date of Birth :-, Age :-, Born :-, Birthplace :-, etc. are consistent through out the sheet.
In Cell F1 enter following formula
=IFERROR(INDEX(B1:D1,1,MATCH("Date of Birth :-",INDEX(LEFT(B1:D1,16),0),0)),"")
In Cell G1 enter
=IFERROR(INDEX(B1:D1,1,MATCH("Age :-",INDEX(LEFT(B1:D1,6),0),0)),"")
And in Cell H1 enter following array formula
=IFERROR(INDEX(Sheet1!B1:D1,1,MATCH(1,("Born :-"=LEFT(Sheet1!B1:D1,7))+("Birthplace :-"=LEFT(Sheet1!B1:D1,13)),0)),"")
Drag/Copy down all formula as required. Change B1:D1 to your column range. See image for reference.
Note : Array formula needs to be committed by pressing Ctrl+Shift+Enter.
If you want result in different sheet then, assuming your data is in Sheet1 and you want output in Sheet2.
Enter following formula in Cell A1 of Sheet2
=Sheet1!A1
Then enter following formula in Cell B2 of Sheet2
=IFERROR(INDEX(Sheet1!B1:D1,1,MATCH("Date of Birth :-",INDEX(LEFT(Sheet1!B1:D1,16),0),0)),"")
Enter following formula in Cell C2 of Sheet2
=IFERROR(INDEX(Sheet1!B1:D1,1,MATCH("Age :-",INDEX(LEFT(Sheet1!B1:D1,6),0),0)),"")
Finally in Cell D2 enter following array formula
=IFERROR(INDEX(Sheet1!B1:D1,1,MATCH(1,("Born :-"=LEFT(Sheet1!B1:D1,7))+("Birthplace :-"=LEFT(Sheet1!B1:D1,13)),0)),"")
Drag/Copy down all formula as required. Change B1:D1 to your column range. See image for reference.
Related
I have a column that contains text cells and date cells. Next to each cell of text, I need the nearest cell that is above that text and contains a date to be returned.
Example
You can use INDEX/MATCH:
=IFERROR(INDEX($A$1:A1,MATCH(1,$A$1:A1,-1))/(ISTEXT(A1)),"")
You have to use a column agent (English is my second language so please give me a better way to describe it if you know), let's say column C.
Put this formula to C1:
=A1
Put this formula to C2 and fill down:
=IF(ISERROR(DATE(DAY(A2),MONTH(A2),YEAR(A2))), C1, A2)
The above formula check if A2 is a date then copy it or fill it down by the cell above.
Copy the cells you want in column B (B2:B4,...) from column C. Hide column C if you want.
Try below formula.
=IF(ISTEXT(A1),AGGREGATE(15,6,$A$1:$A$10,COUNTIF($A$1:$A1,">1/1/1900")),"")
If there are numbers also in cells rather that names then you can use below formula
=IF(LEFT(CELL("format",A1),1)="D","",AGGREGATE(15,6,$A$1:$A$10,COUNTIF($A$1:$A1,">1/1/1900")))
You can also use the LOOKUP function:
B1: =IF(ISNUMBER(A1),"",LOOKUP(2,1/($A$1:A1),$A$1:A1))
and fill down.
https://i.stack.imgur.com/WJAS0.png (Sorry for the link, I don't have enough rep to post an image)
I'm trying to get a formula where if any of the values found in column D (taking into account that some cells have multiple values ie. cell D4) match a value in Column A then return the value of the same row associated with Column D.
For example, in cell D4 the number 786403213972 matches A2 then cell C4 will return 100.
Following up on your last question here, hereby a way to do this (beware, it's long and tricky)
Formula in C2:
=IF(SUMPRODUCT(--(ISNUMBER(SEARCH(TRIM(MID(SUBSTITUTE(D2,CHAR(10),REPT(" ",99)),(ROW(OFFSET($A$1,,,LEN(D2)-LEN(SUBSTITUTE(D2,CHAR(10),""))+1))-1)*99+((ROW(OFFSET($A$1,,,LEN(D2)-LEN(SUBSTITUTE(D2,CHAR(10),""))+1)))=1),99)),TRANSPOSE($A$2:$A$7)))))>0,B2,"")
Confirm as array formula through Ctrl+Shift+Enter
Drag down...
I have this row, and want to know the value of the first row (dates) of the last non-empty cell. In this example, it should return 1/11/2018. Given the input of "Stock A", how do I achieve this using Excel formulas?
Try:
=LOOKUP(2,1/(A2:Y2<>""),A1:Y1)
Courtesy #barry houdini.
Assuming the data is in Sheet1, and your lookup stock code ("Stock A" in this case) is on Sheet2 cell A2, use this formula in sheet2, cell B2 to get the desired date (adjust range references to suit your actual data):
=LOOKUP(2,1/(INDEX(Sheet1!$B:$M,MATCH(A2,Sheet1!$A:$A,0),0)<>""),Sheet1!$B$1:$M$1)
Note that you'll probably need to format the formula cell as a Date so it displays the date properly instead of the Excel Datecode.
I need to insert a value to a cell in excel using formula in another cell.
Say
A1 = "Test"
B1 = formula to insert A1 to C1
C1 = A1
Can I write a formula in B1 to insert value in C1?
I don't need any formulas in C1.
If Yes, What should be the formula?
If there it is next to the cell AND has no value in B2, it is possible, otherwise it is not.
Use Split()
Split(CONCATENATE("Text for B1#Sperator$$",A1),"#Sperator$$",FALSE)
It really depends.
EDIT
Out dated. Only works in google sheets.
Without using VBA or formulas in column C you can't achieve this.
A simple solution using formulas:
In cell C1, paste the following formula and drag it down:
=IF(B1=1;A1;"")
So if the content of cell B1 is equal to 1, your cell at column C will display the respective value of the same row at column A.
I have the following range in column A :
01-Mar-12
01-Apr-12
01-May-12
01-Jun-12
01-Jul-12
01-Aug-12
01-Sep-12
01-Oct-12
01-Nov-12
01-Dec-12
01-Jan-13
01-Feb-13
01-Mar-13
01-Apr-13
01-May-13
01-Jun-13
01-Jul-13
01-Aug-13
01-Sep-13
In column B, I would like the same list of dates ( i.e. March 12 -> Sep 13), but I would like every August to be duplicated:
01-Mar-12
01-Apr-12
01-May-12
01-Jun-12
01-Jul-12
01-Aug-12
01-Aug-12
01-Sep-12
01-Oct-12
01-Nov-12
01-Dec-12
01-Jan-13
01-Feb-13
01-Mar-13
01-Apr-13
01-May-13
01-Jun-13
01-Jul-13
01-Aug-13
01-Aug-13
01-Sep-13
I can add as many columns in between as I like, but it must be done with formulae.
I'm having a little trouble figuring this out - any help would be much appreciated.
A formula is not capable of inserting rows.
Copy ColumnA to ColumnB, insert a cell and shift down immediately under each Aug and in the blanks created enter:
=R[-1]C
This formula works, assuming the values in column A are unique. Paste the formula into cell B3.
=IF(AND(MONTH(B2)=8,MONTH(B1)<>8),B2,INDEX(A:A,MATCH(B2,A:A,0)+1))
The current formula assumes that B1 and B2 are part of the list in column B. You'll have to manually fill in the values for B1 and B2 unless you change the formula a little.
What the formula does:
If B2 is August and B1 is not, then B3 copies the value of B2.
Otherwise B3 is the date in Column A found under the date B2.
You can then copy the formula into the remaining cells below B3.