Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL-SELECT HELP
Message
 
 
À
23/01/2001 10:05:36
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00467274
Message ID:
00467303
Vues:
14
>Hi All,
>
>I would like to use SELECT command to search only in one table (DBF).
>Could anyone help me with some codes ?
>
>TableEx.dbf contained three fields :
>
>IDNUMBER DATE CODE
>
>11111 01/01/01
>11111 01/02/01 X
>11111 01/03/01
>11111 01/04/01
>22222 01/01/01
>22222 01/02/01
>22222 01/03/01
>22222 01/04/01
>33333 01/01/01
>33333 01/02/01
>33333 01/03/01 Y
>33333 01/04/01
>
>after used SELECT and DELETE, I should have only one IDNUMBER
>left in the TABLEEX.DBF means every IDNUMBER who had no blank CODE
>should be deleted from the table.
>
>22222 01/01/01
>22222 01/02/01
>22222 01/03/01
>22222 01/04/01
>
>Thanks in advance,
>Paul
DELETE FROM Mytable ;
	WHERE IdNumber IN ;
             (SELECT DIST IdNumber FROM Mytable WHERE Code <> SPACE(1))
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform