ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Populate and entire row while removing duplicates. (https://www.excelbanter.com/excel-discussion-misc-queries/203863-populate-entire-row-while-removing-duplicates.html)

NightLord

Populate and entire row while removing duplicates.
 
I'm kicking myself in butt here.
I have two sheets. In Sheet 1, Column B there is a row of names- some of
which are duplicates. Bob will show up as often as he has called in.

In Sheet two, I want Column A to populate itself with every name that shows
up in Sheet 1, Columb B... but only once for each name. Thus, even though Bob
has called in 100 times, I just want his name to show up once on Sheet 2.

I'm having isses because I want the Column in sheet 2 to be dynamic. I tried
a pivot table, with a CountIf function, but for the layout it wants something
in the field next to it. I JUST want the row to do the names. Nothing more.

Max

Populate and entire row while removing duplicates.
 
In Sheet two, I want Col A to populate itself with every name that shows
up in Sheet 1, Col B... but only once for each name.


Here's one way to drive it out dynamically in Sheet2

Source names assumed in Sheet1, in B2 down

In Sheet2,
In A2:
=IF(Sheet1!B2="","",IF(COUNTIF(Sheet1!B$2:B2,Sheet 1!B2)1,"",ROW()))
Leave A1 empty

In B2:
=IF(ROWS($1:1)COUNT(A:A),"",INDEX(Sheet1!B:B,SMAL L(A:A,ROWS($1:1))))
Select A2:B2, copy down to cover the max expected extent of source data in
Sheet1's col B, say down to row 500? Hide away or minimize col A. Col B will
return the required results, all neatly packed at the top
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:18,100 Files:360 Subscribers:56
xdemechanik
---

Sheeloo[_2_]

Populate and entire row while removing duplicates.
 
Formula adapted from another post...

Assuming you have names in Sheet 1 Col B upto row 1200, no header row
Enter in C1
=COUNTIF(B1:$B$1200,B1) copy down till C1200

Go to Sheet 2
in B1 paste the following
=IF(ROWS($1:1)<=COUNTIF(Sheet1!C$2:C$1200,1),INDEX (Sheet1!B$2:B$1200,SMALL(IF(Sheet1!C$2:C$1200=1,RO W(Sheet1!B$2:B$1200)-ROW(Sheet1!B$2)+1),ROWS($1:1))),"")
and press CTRL-SHIFT-ENTER and copy down... till you get a blank. You may
copy it further down for future additions of names in Sheet 1.

"NightLord" wrote:

I'm kicking myself in butt here.
I have two sheets. In Sheet 1, Column B there is a row of names- some of
which are duplicates. Bob will show up as often as he has called in.

In Sheet two, I want Column A to populate itself with every name that shows
up in Sheet 1, Columb B... but only once for each name. Thus, even though Bob
has called in 100 times, I just want his name to show up once on Sheet 2.

I'm having isses because I want the Column in sheet 2 to be dynamic. I tried
a pivot table, with a CountIf function, but for the layout it wants something
in the field next to it. I JUST want the row to do the names. Nothing more.



All times are GMT +1. The time now is 10:06 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com