Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP60- Dabatases and Tables
Message
De
27/12/1999 17:20:54
 
 
À
27/12/1999 16:29:29
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00308802
Message ID:
00308970
Vues:
36
Not sure what your asking. If you wantto save the results to a table, you can use

COPY TO c:\mytable


>Thank you for your time, that command is working great. Now, is there an easy way to save the dup records in this table using a SELECT command?
>
>>>Hello Erik,
>>>The real table has 70 fields. Do I have to specify the 69 fields in the GROUP BY clause?
>>>
>>>>>I have a table with 5 fields and I'd like to get rid of the dup records base of 4 fields. The SELECT DISTINCT command doesn't work in this case because it compares the whole record.
>>>>>
>>>>>Any sugestions? Thank you in advance.
>>>>
>>>>you can choose your criteria for your uniqueness check with the GROUP BY clause:
>>>>
>>>>SELECT COUNT(*), * FROM Mytable GROUP BY Field1, Field2, Field3, Field4 HAVING COUNT(*) > 1
>>
>>The group by clause contains only the fields you want to use to determine uniqueness. If you are basiing your definition of uniquness on the contents of 4 fields, put those for fields in the GROUP BY clause.
Erik Moore
Clientelligence
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform