Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Unique records SQL
Message
From
28/03/2003 16:30:04
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00771570
Message ID:
00771572
Views:
10
>Hi,
>How can I use a select statement to get only the unique records from a dbf?
>Steve
select * from MyTable group by Field1, Field2
Here, the combination of Field1 and Field2 is supposed to be unique.

Or, to check for combination of all fields, use DISTINCT:
select distinct * from MyTable
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform