Getting data from two columns in Excel, adding new rows automatically - excel

Is it possible to get data from two columns (using comma as a delimiter) and have it insert new rows for each comma? I'm trying to fix data entered in a form, where multiple first names and multiple emails were entered in one row; EG col A has "John, Annie, Frantubulous" and Col B [email] contains "john#dumb.com, Annie#aol.com, frantan69#gmail.com" all in one row. I want to separate each entry (marked by commas) into its own line and not manually have to comb each of the entries and add new rows.
Thanks

Related

split delimited row into multiple rows

I hope you can give me some guidance.
I have this first table with two comma delimited cells:
=>I separated the delimited values of the last column with power query. Split rows and remove the pivot (https://exceloffthegrid.com/power-query-split-delimited-cells-into-rows/):
=>My question is for the second column, how can I avoid that it generates the matrix product and only put a single value in the cell?
I want to get the table like this:
You could add 2 more steps:
Between first and second table above you may create and process a new column with combined values „d-1, e-2, f-3“ and “y-4, x-5” before unpivot.
After unpivot split the columns with the combined values to 2 columns back.

Return non-blank rows from a range in a new range list in Excel

Using Excel, assumed there is a range of data including text and number values. But some are blank rows. How could I create a range of list which only includes non-blank rows using Excel functions? Thus, I don't have to copy, paste and remove blank rows by daily.
For example, Raw data table as below,
AAA 111 111 111 111
BBB 111 111 111 111
AAA 111 111 111 111
CCC 111 111 111 111
QQQ 111 111 111 111
SSS 111 111 111 111
BBB 111 111 111 111
Then, create a new range of table like this,
AAA 111 111 111 111
BBB 111 111 111 111
AAA 111 111 111 111
CCC 111 111 111 111
QQQ 111 111 111 111
SSS 111 111 111 111
BBB 111 111 111 111
I was trying to use this formula. However, it doesn't work...
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F1:J1))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F2:J2))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F3:J3))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F4:J4))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F5:J5))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F6:J6))),"")}
{=IFERROR(INDEX($A$1:$E$12,SMALL(IF($A$1:$E$12<>"",ROW($A$1:$E$12)),ROW(F7:J7))),"")}
IF($A$1:$E$12<>"",ROW($A$1:$E$12)) in array context will result in a row vector {1,1,1,1,1} in case of row 1. So it always results in 5 times either the row number or FALSE for each row. So you will get each not empty row number 5 times.
One option would be only checking if column A is empty and having the array formula for each single cell instead of the single rows:
{=INDEX($A$1:$E$20,SMALL(IF($A$1:$A$20<>"",ROW($A$1:$A$20)),ROW(1:1)),COLUMN(A:A))}
Example:
Of course this is really not performant for big ranges. But I don't see another possibility using formulas.
What I would do is having a helper column using the array formula:
{=AND(A1:E1<>"")}
for each row.
And then sorting the table by this helper column descending.

Excel: Reflecting changes of some columns on one other when a record inserted or removed in first columns set

Assume I have two columns A, B
Source Data:
Then I want to have a column in another part of my same excel sheet or another excel sheet (same document) which makes a decision to show values on column A according to column B (Using if function : show A if B = 1 or else show 0).
My goal is this:
1) When somebody inserts a record in source data (A, B) or removes a record it reflects to second part automatically (new record insert or remove in results part)
2) I don't want to put results in the same rows. In this example source data started from row 3 but I like to put result from first row or row number 100 onward
Thank you in advance

Match two columns in table to two columns in separate table and return value

I have two tables on separate sheets in the same workbook.
Trying to explain: I am trying to return the length in worksheet("LENGTHS") to worksheet("CONTROL"). Basically, if D3&E3 (Ex. L1a) matches worksheet("LENGTHS")B:B&C:C, return value in column D to worksheet("CONTROL")column G.
Worksheet("CONTROL")
Worksheet("LENGTHS")
I am able to match just the "REF:" columns with:
=IFERROR(INDEX(Table2[[#All],[Linear Length:]],MATCH([#[REF:]],Table2[[#All],[REF:]],0)),"")
However, I need to match the extensions in the adjacent column as well. I tried adding it with "&" but it returns a blank cell:
=IFERROR(INDEX(Table2[[#All],[Linear Length:]],MATCH([#[REF:]]&[#[(extension)]],Table2[[#All],[REF:]]&Table2[[#All],[Extension:]],0)),"")
Any suggestions appreciated. Writing a macro might take less space?

Keep first n values in a column

I'm working with an Excel file with more than a hundred columns containing thousands of values. However, I only need the first 504 values in each column and the remaining values in that same column need to be removed. The problem is that the values in the columns start in different rows.
Is there a solution to this problem?
I would suggest creating a filter for the entire worksheet and filter out null values giving you a selection of good data or delete the null values using the filter to select the null values. From there, delete the lines below your desired range.
I think you need to write a macro for that.
Your macro will scan your current sheet and will copy selected cells to
a new target sheet.
The macro has to include 2 loops:
outer loop will run on columns
inner loop will run on cells on curnet column
for each column
The inner loop will advance from cell 1 upwards untill it finds first cell
that its not null, when it finds it you have to write code that will copy
the next 504 cells on that same column to the target sheet
then the control will go to the outer loop that will increment to the next
column
you can assign Constant for MAX_COLUMNS that when the code reaches it
the macro will end.

Resources