Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default Question... Marking the unique- and the first one of the doubles with1 or 0 in the column next

Hello,

If somebody can optimize something that I tried to solve with formulas :(
A macro should be nice and more efficient.

A Loop in column AC for all records from 2 till last.
This column exist of several records with a lot of doubles in it.

It's not a problem to identify them (like CountIf), but...... I had to follow up something which should be related to only the uniques (the 'no' doubles) and the first one of the 'yes' doubles.

Is there an easy way to set in column AD the number "1" if it is the only one (no doubles in the list) or the first one (the first of the doubles) and a zero "0" if a double was earlier in the list and already foreseen with a 1 in column AD


Like

AC AD

AAA 1
BBB 1
AAA 0
CCC 1
DDD 1
AAA 0
EEE 1
EEE 0
AAA 0
FFF 1

Everybody have a nice Easter and not to much eggs :)

Regards, Johan


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,872
Default Question... Marking the unique- and the first one of the doubles with 1 or 0 in the column next

Hu Johan,

Am Fri, 19 Apr 2019 05:01:34 -0700 (PDT) schrieb :

AC AD

AAA 1
BBB 1
AAA 0
CCC 1
DDD 1
AAA 0
EEE 1
EEE 0
AAA 0
FFF 1


the easiest way is a formula. Try in AD2:
=--(AANTAL.ALS(AC$2:AC2;AC2)=1)
and copy down


Regards
Claus B.
--
Windows10
Office 2016
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default Question... Marking the unique- and the first one of the doubleswith 1 or 0 in the column next

Sometimes Excell looks really simple.
Claus thanks a lot.

in English formula;
=COUNTIF(AC$2:AC2;AC2)=1 (and then copy down)

Works as requered :)

regards, Johan
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how do i get rid of doubles from my database? Bill Excel Discussion (Misc queries) 2 April 27th 10 07:55 AM
Filer for unique records and return all column data for unique rec bseeley Excel Discussion (Misc queries) 1 September 12th 09 12:17 AM
Sorting doubles rbrunz Excel Discussion (Misc queries) 1 June 13th 08 04:20 PM
xls size doubles kirkm[_7_] Excel Programming 0 December 22nd 07 01:03 AM
Comparing Doubles big t Excel Programming 1 September 20th 04 10:16 AM


All times are GMT +1. The time now is 08:23 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"