Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sorting of Results from SQL
Message
De
07/10/1998 07:41:55
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00144507
Message ID:
00144510
Vues:
18
>Using a SQL statement, I extract ten data records on the basis of highest to lowest value. So I might have ten records with $10.00 at the top and $1.00 at the bottom. If there are more than one record with the same value, they need to be listed but in order by a second value, perhaps zip code. Is there a way to implement this inside the SQL statement?

In you ORDER BY clause you can include multiple columns for ordering, either by column name or column number, so

ORDER BY 1, 3, 4

would order by column 1 first, then sub-order by column 3, then coulmn 4, etc.

Bill
William A. Caton III
Software Engineer
MAXIMUS
Atlanta, Ga.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform