Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Duplicate values
Message
From
02/01/2001 17:20:15
 
 
To
02/01/2001 17:10:21
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00458671
Message ID:
00458679
Views:
17
>How can I scan a table and find duplicate values in a particular field? I want to create a primary index on two fields and it tells me it can't be done because of dups.

Assuming the 2 fields are Field1 and Field2:
Select Field1, Field2, Count(*) ;
  From mytable ;
  Group By Field1, Field2 ;
  Having Count(*) > 1 ;
  Into Cursor cuDupes
Insanity: Doing the same thing over and over and expecting different results.
Previous
Reply
Map
View

Click here to load this message in the networking platform