Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Worksheet Functions / October 2007

Tip: Looking for answers? Try searching our database.

Display a 1 for the first of duplicates

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
noelle - 04 Oct 2007 07:54 GMT
I have a list of records that have many duplicates. I need a formula that I
can use in the adjacent column to show a 1 for the first instance of a
duplicate and a 0 for any others.  The list is sorted so all dupes are
together.
Stefi - 04 Oct 2007 08:29 GMT
Try this formula:
=--(MATCH(A2,A:A,0)=ROW(A2))
and drag it down as required!

Regards,
Stefi

„noelle” ezt írta:

> I have a list of records that have many duplicates. I need a formula that I
> can use in the adjacent column to show a 1 for the first instance of a
> duplicate and a 0 for any others.  The list is sorted so all dupes are
> together.
noelle - 04 Oct 2007 15:10 GMT
Great, thanks.  That worked!

Would you mind explaining the components so I understand how it works?  It's
really been bugging me that I can't figure this out!

Thanks again.

> Try this formula:
> =--(MATCH(A2,A:A,0)=ROW(A2))
[quoted text clipped - 9 lines]
> > duplicate and a 0 for any others.  The list is sorted so all dupes are
> > together.
Excel_Learner - 04 Oct 2007 10:16 GMT
Use this formula in cell B3:

=IF(COUNTIF(C$3:C3, C3)=2, 1, 0)
Let me know if it works.

> I have a list of records that have many duplicates. I need a formula that I
> can use in the adjacent column to show a 1 for the first instance of a
> duplicate and a 0 for any others.  The list is sorted so all dupes are
> together.
AdamV - 04 Oct 2007 12:13 GMT
Note that the first solution above will flag the first occurence of each
value (duplicate or otherwise); the second solution will flag the second
occurence (=the first duplicate, literally). Choose the one that actually
matches your need.

Signature

Adam Vero
MCP, MOS Master, MLSS, CWNA
http://veroblog.wordpress.com
http://www.meteorit.co.uk

> Use this formula in cell B3:
>
[quoted text clipped - 5 lines]
> > duplicate and a 0 for any others.  The list is sorted so all dupes are
> > together.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.