Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Get the most recent dates
Message
De
07/10/2010 15:52:18
 
 
À
07/10/2010 15:21:31
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
01484398
Message ID:
01484405
Vues:
50
>Hi,
>
>I have mytable that contains 2 fields:
>
>id date
>aaa 20101006
>aaa 20100906
>
>bbb 20101007
>bbb 20100907
>
>to create newtable with 2 records left from 4 above:
>aaa 20101006
>
>bbb 20101007
>
>I need to have a sql syntax to do this.

Something like
SELECT ;
  ID ;
  , MAX( Date ) AS MaxDate ;
  FROM ... ;
  INTO TABLE ... ;
  GROUP BY ID ;
  ORDER BY ID
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform