Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Asort
Message
De
03/12/1998 20:13:29
 
 
À
03/12/1998 20:01:40
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Re: Asort
Divers
Thread ID:
00163910
Message ID:
00163913
Vues:
27
>I type - USE Mytable - SET ORDER TO Myfield - COPY TO ARRAY Myarray FIELD Myfield - Myarray is now a list of numbers from a numeric field in ascending order. At this point I cannot seem to get the syntax correct for the next command, which is an ASORT( ) that will reverse the sort order to descending. How do I refer to the first element without adding an extra comma to the ASORT( )?

Easiest woulde be to redo your method of building the list. Instead of:

USE MyTable
SET ORDER TO MyField
COPY TO ARRAY MyArray FIELD MyField

Why not:
SELECT MyField ;
  FROM MyTable ;
    TO ARRAY MyArray ;
 ORDER BY MyField DESC
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform