Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Group 2 fields, omit duplicate values
Message
De
28/10/2010 12:15:04
 
 
À
28/10/2010 10:09:02
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01487370
Message ID:
01487406
Vues:
58
>Hi,
>Help please,
>
>I have cursor (name is mycursor) with two fields .
>Example:
>
create cursor test (fld c(4))insert into test values ('ABC')
>insert into test values ('CBA4')
>insert into test values ('BDC')
>insert into test values ('EG')
>insert into test values ('C22F')
>insert into test values ('2DB')
>insert into test values ('FE')
>insert into test values ('ADER')
>
>select fld as fld1 from test into cursor test1
>select fld as fld2 from test into cursor test2
>
>select * from test1,test2 into cursor mycursor
>
>on "Mycursor" you can see one row with fld1=ABC and fld2=BDC and another row with with fld1=BDC and fld2=ABC.
>How can I void it? (it is not important form me what to omit).
>
>sorry for my poor english
>Tnx

try
select * from test1 JOIN test2 on fld1 <= fld2
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform