Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Filtering without Group By and Having ?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00590837
Message ID:
00590864
Vues:
20
>I have a table with a status column value of "Ready for processing..." or "Processing complete...". Some rows have both values, others have just the "Ready for processing..." value. I want to find those rows that just have the first value. But I can't use group by or having. Can anyone recommend a fast way to get around this?
>
>
>Select iBatchID , cFileName , cStatusDesc From xxx ;
>	Where cFileName like '\\vanbustest\SCCFiles$\scc\staging\dev\standard\01102301.120%' ;
>	and cStatusDesc not like 'Ready for processing%' ;
>Group by iBatchID ;
>Having cStatusDesc not like 'Processing complete%'
Steve;
Select iBatchID , cFileName , cStatusDesc From xxx ;
	Where cFileName like "\\vanbustest\SCCFiles$\scc\staging\dev\standard\01102301.120%" ;
	and cStatusDesc  =  "Ready for processing" ;
        into cursor mycursor
The use of Like will slow things down but is sometimes necessary.

Tom
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform