My data doesn't automatically continue when I add info into its associated table

carrrrlitos17

New Member
Joined
Jul 7, 2022
Messages
15
Office Version
  1. 365
Platform
  1. Windows
Hello again,

I find myself with two problems.

Context: I have a table that lists out what each company supplies. If there are multiple products for a company, the company is relisted plus all the contact info and thus, it can get a little repetitive (See img. Table). To combine the info, I had to make that last column to list the combined info, with the function being =COUNTIF($E$2:E2,E2)&":"&TEXTJOIN("|",,D2,B2)

I then made another sheet where companies can be listed and each of their products be listed all in one row, followed by their contact info (so each company only has one row not multiple) (See img Current new sheet).

Continuing to look at that image from left to right, my functions in each Column are as follows:

=UNIQUE(Table2[Company])

=TEXTJOIN(CHAR(10),,FILTER(Table2[For Table],Table2[Company]=A22))

=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table2[Contact],Table2[Company]=A22," ")))


I have noticed that when I add a new line(s) to the original table, my process becomes sloppy.

Problem 1) In the table, my last column function seems to lose track and appears like this (see New Table) I notice that the function on what had once been the last row changes from being =COUNTIF($E$2:E261,E261)&":"&TEXTJOIN("|",,D261,B261)
to
=COUNTIF($E$2:E263,E261)&":"&TEXTJOIN("|",,D261,B261)

The problem lies in the range area of the COUNTIF, how do I allow it to keep updating forward?

Problem 2) (see problem 2) the only thing that carries over is the Unique function that lists the company, but the other columns dont fill in.

All in all, my goal is to be able to add new companies to my table and have that data be added to my other sheet without a problem.

Thank you, sorry for the wordy explanation
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Change your formulas to use structured referencing - you'll probably want to use INDEX
 
Upvote 0
This:

Excel Formula:
=COUNTIF($E$2:E261,E261)&":"&TEXTJOIN("|",,D261,B261)

is not structured referencing. What are the names of the table columns for column E, D and B?
 
Upvote 0
This:

Excel Formula:
=COUNTIF($E$2:E261,E261)&":"&TEXTJOIN("|",,D261,B261)

is not structured referencing. What are the names of the table columns for column E, D and B?
Oh I see, the column names are Company, Product/Service, and Type, respectively
 

Attachments

  • Tuesday.png
    Tuesday.png
    18.5 KB · Views: 4
Upvote 0
Try:

Excel Formula:
=COUNTIF(INDEX([Company],1):[@Company],[@Company])&":"&TEXTJOIN("|",,[@[Product/Service]],[@Type])
 
Upvote 0
Try:

Excel Formula:
=COUNTIF(INDEX([Company],1):[@Company],[@Company])&":"&TEXTJOIN("|",,[@[Product/Service]],[@Type])
That seems to do the trick for the Table WorkSheet, thank you so much! As for the second question, I am still having difficulty with it.

If you take a look at Img 1, this is how it currently updates, but as you can see the For Table info (that being the info you just helped me with) nor does the contact info (contact name, email, and phone number) carry over. In the Table Test pic you can see how it currently shows up on the table. How can I have it so the table info goes to the other sheet?

My Formulas from Left to right
=TEXTJOIN(CHAR(10),,FILTER(Table2[For Table],Table2[Company]=A164, " "))
=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table2[Contact],Table2[Company]=A164," ")))
=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table2,Table2[Company]=A164," ")))
=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table2[Phone Number],Table2[Company]=A164," ")))
 

Attachments

  • IMG 1.png
    IMG 1.png
    10.5 KB · Views: 5
  • Table test.png
    Table test.png
    8.5 KB · Views: 6
Upvote 0
It doesn't look like the data in the first image is in a table, so you need to use dynamic array formulas on that sheet in order for them to automatically spill down. It would be easier to help if you could either post a link to a file or use XL2BB to post samples of data that we can actually work with, rather than pictures.
 
Upvote 0
Here is the Table

For Excel Site.xlsx
ABCDEFGH
1
2SystemTypeProduct/ServiceCompanyContactEmailPhone For Table
3Internal SystemsupplierPuzzlesCompany ASteve Steve@gmail.com780931741:Puzzles|supplier
4Internal SystemsupplierDominoesCompany BKarloKarlo@gmail.com123470981:Dominoes|supplier
5Internal SystemsupplierPuzzlesCompany BKarloKarlo@gmail.com123470982:Puzzles|supplier
6Internal SystemInstallerJacksCompany CAbeAbe@gmail.com432870131:Jacks|Installer
7Internal SystemSupplierMarblesCompany DTrishatrisha@gmail.com53245281:Marbles|Supplier
8
9
Table
Cell Formulas
RangeFormula
H3:H7H3=COUNTIF(INDEX([Company],1):[@Company],[@Company])&":"&TEXTJOIN("|",,[@[Product/Service]],[@Type])


And Here is the sheet I want to have updated. As you can see, Company D with contact Trisha was recently inserted into this table, but it won't update on the second sheet.
Cell Formulas
RangeFormula
A3:A6A3=UNIQUE(Table1[Company])
B3:B5B3=TEXTJOIN(CHAR(10),,FILTER(Table1[For Table],Table1[Company]=A3, " "))
C3:C5C3=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table1[Contact],Table1[Company]=A3," ")))
D3:D5D3=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table1[Email],Table1[Company]=A3," ")))
E3:E5E3=TEXTJOIN(CHAR(10),,UNIQUE(FILTER(Table1[[Phone ]],Table1[Company]=A3," ")))
Dynamic array formulas.
 
Upvote 0
Do you have BYROW and LAMBDA functions available to you?
 
Upvote 0

Forum statistics

Threads
1,215,025
Messages
6,122,734
Members
449,094
Latest member
dsharae57

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top