I want to combine duplicate values in column B and merge values from Column A - duplicates

I've tried to search the web for this one, but no luck. Hoping someone can help me out.
I currently have a sheet with multiple duplicate account numbers. I want to combine the account number and display the one account number, but list out all the phone numbers associated to that account number separated with a semi colon. Hoping someone can help me with an app script to automate this process.
Original file
I would like it to look like this:
Ideal File

Related

Syncing a List between different sheets keeping properties sticked to a row

Maybe the title is not explicit enough, but what do I want to achieve, is:
I want to have a single place to edit a list (customers) with some metadata, to be used across the entire spreadsheet.
Some sheets may contain editable data as rows tied to the 1st column with the customer Ids. E.g. prices for services for each Customer for each month.
So, when I add an entry (Customer) to the 1st (master) sheet, it appears in the pricing table and doesn't break the existing entries (the rows remain connected).
So far I've not found any native solution for this. Should I look for extensions fo this, or code it using the app script?

Is there any way to deduce city, state, and/or zip code from a phone number in Google Sheets?

I have a Google Sheets list of about 5,000 customers, almost all of which have phone numbers associated. Since many of our customers are from large companies with multiple offices, I'd like to segment as many as possible into their respective office locations. I thought that if possible to do this easily, it would probably be done using the area code of their work phone number. Does anyone know of a way to use that 3-digit area code to return city/state or zip code in Google Sheets?
One possible solution is to create another table that has states and their associated area codes(data can be cut and pasted into your sheet from here: https://www.freshworks.com/freshcaller-cloud-pbx/phone-numbers/us-area-codes/). Then once you have that those two tables you can perform a table merge between your customer table and the area code table(explanation with example here: https://davidmeindl.com/the-ultimate-google-sheets-formula-to-join-two-tables/).

Similar to UNIQUE customers by date

I'm trying to create an organizer to my payments sheet, it's a sheet that receives all payments and I want to show only the last payment for each user, I want do this to know how much time user stay with us!
I don't have idea how to do it, I'm trying use UNIQUE but this doesn't work fine!
Can you help me?
Demo sheet: https://docs.google.com/spreadsheets/d/169FgYI4v43WnFhAlcfrXnOtzvBKMNbQBvGsQ7W41HcE/edit?usp=sharing
I've set up a new sheet called "Erik Help" with this formula in F1 (highlighted bright green):
=ArrayFormula({"Client name"\"Payment date";VLOOKUP(UNIQUE(FILTER(B2:B;B2:B<>""));SORT(B2:C;2;0);{1\2};FALSE)})
You can see that the formula generates the headers first.
Underneath that, the unique list of clients ...
UNIQUE(FILTER(B2:B;B2:B<>""))
... is looked up within a SORT of the client and payment data, sorted descending by date (which leaves the most recent dates at the top and working down).
The virtual range {1\2} is returned, which is each name and date from the UNIQUE list.
Since VLOOKUP only returns the first match it finds (if any), you'll always get the most recent date per client.
I am not sure where is the data I should use within your sheet. So let's work on dummy table (it's in your spreadsheet as sheet 'Dummy'):
First I take a list of transaction and get unique client names:
=unique(B2:B)
Then I use vlookup formula to search for the first appearance of the client on payment list.
Ifna is used to hide error messages
Arrayformula makes vlookup possible to work on whole column without copying.
=ArrayFormula(ifna(vlookup(G2:G;$B$2:$C;2;true)))

Consolidate response data from Google Form submissions where the respondents have the same name

I thought I could figure this out, but it seems I can't. Basically, students' information will be input to Google Sheets through Google Forms, but due to my Google Forms having sections, the data of one student appears in different rows. Each student rates 4 subjects, and they each have 4 teachers; the form separates each subject area into sections and Google Sheets places this info into 4 different rows.
I'm trying to consolidate all the data that has an identical name into one row, rather than appearing in 4 different rows. I've recreated what my data currently looks like in this example spreadsheet.
Any help would be much appreciated, this is driving me mental!
You could do it with a lot of VLOOKUP's.
Suppose you put the list of names in A21:A24
=unique(C2:C11)
Then do a lookup on each Name/subject pair in the appropriate column
=ArrayFormula(iferror(vlookup(A21:A24&{"Math","Math","English","English","Science","Science","HSIE","HSIE"},{C2:C11&D2:D11,E2:N11},{2,3,4,5,6,7,8,9},false),""))
Explanation
Maybe the way to explain it is to build it up from the case of one student - one subject to many students - many subjects? This assumes that you've got a list of student's names in A21:A24 and you want to pull out the info for each of them from the original data.
(1) One student, one subject
Hopefully trivial - just provide a reference to the student's report
=E2
(2) Several students, one subject (maths) (Names not necessarily in same order as original list)
Use vlookup to get report against each name
=ArrayFormula(vlookup(a21:a24,C2:E11,3,false))
It's an array formula so that it works through each of the 4 names, finding the first report associated with each. Note that it would pick up a blank for Susan in your data, because the first row with Susan in it contains a blank for maths.
(3) Several students, several subjects
=ArrayFormula(iferror(vlookup(A21:A24&{"Math","Math","English","English","Science","Science","HSIE","HSIE"},{C2:C11&D2:D11,E2:N11},{2,3,4,5,6,7,8,9},false),""))
So here it's looking up pairs like
BobMath BobMath BobEnglish BobEnglish...JimMath JimMath JimEnglish...
(student name + first pair of curly brackets)
in an array (second pair of curly brackets) where the first column is
BobMath
JimMath
SusanScience
...
and pulling out the correct row. It's also got to tell vlookup what column to look in (third pair of curly brackets).
So the first vlookup generated by this would be
vlookup("BobMath",array,2,false)
where array contains
BobMath Cross (several other columns)...
JimMath Blue (several other columns)...
...
BillHSIE (several other columns)... Hair
so it would pick up Cross
and the last vlookup would be
vlookup(BillHSIE,array,9,false)
which would pick up Hair.
Now it doesn't pick up a blank for Susan's maths because the first row it looks in is row 9 and it picks up Tickle from column E.
EDIT
If you then wanted to add some columns which only related to the student and not to any particular subject (like 'student attends counselling') you would need a different approach.
=ARRAYFORMULA(IFERROR(VLOOKUP($A21:$A24,FILTER({$C2:$C11,M2:M11},M2:M11<>""),2,FALSE),""))
This does a lookup as in (2) above but first skips any cells which are blank in the particular column being used for lookup. This formula only works on a single column, but can be pulled across for additional columns.

Extracting Values from 300 sheets where vlookup doesn't work

I have an excel spreadsheet which has just under 300 sheets in it. The first sheet has a list of items which are all numbered 1.1.1, 1.1.2 etc. The rest of the sheets have some of the items listed on them and not in numerical order. I am trying to extract the quantity and total listed against these items on all the different sheets.
The sheets are complicated by the fact that they are not well structure so have section titles which are across merged cells.
I could get this information by hand using the search facility in excel and visit each instance of the number and then add up all the quantities and totals by hand. Is there any way I can automate this? i.e. by asking excel to take each unique identifier from sheet 1, find it in the rest of the sheets and return the quantity and/or total?
I tried using vlookup but it only seemed to return one of the values and ignore all the others.
Even if there was a formula that I had to change the unique identifier by hand that would be much quicker!
Thank you for any help you can give. I am not a programmer so constructing the vb by myself would probably take longer than doing it by hand!
If you add a $ before your lookup data for example
search - $A&2:&AZ&1000
then you are telling excel to look for anything in that array.
because if you do not have a $ in and you copy it, it starts excluding everything above that.