Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How can I order the result according to inlist type data
Message
De
13/12/2004 05:17:23
Erick Miranda
Formata Data Business - Grupo Linx
Contagem, Brésil
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
00968680
Message ID:
00968683
Vues:
11
This message has been marked as the solution to the initial question of the thread.
Hi Ali,
>select customer_id  ;
>  from Customer ;
> where customer_id in (16, 10, 12, 15, 8, 1) ;
>  into cursor curCustormer
>How can I order the result cursor according to data in the set of inlist expressions
>Thank in advance
>Ali Altun

Try:
select customer_id,  ;
  iif(customer_id = 16, 0, iif(customer_id = 10, 1, iif(customer_id = 12, 2, iif(customer_id = 15, 3, iif(customer_id = 8, 4, 5))))) myNewField ;
  from Customer ;
 where customer_id in (16, 10, 12, 15, 8, 1) ;
  order by myNewField ;
  into cursor curCustormer
I hope this helps you.
Bye!
Erick
Força Sempre!
Strength Always!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform