Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why there is a difference - accounts missing...
Message
 
 
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
Database:
Visual FoxPro
Divers
Thread ID:
01079769
Message ID:
01079785
Vues:
12
>Hi everybody,
>
>Why these two would return different results?
>
>SELECT COUNT(cTrans_pk) FROM Trans ;
>INNER JOIN trans_Employees_Queues ON Trans.ctrans_pk = Trans_Employees_Queues.ctrans_fk AND ;
> Trans_Employees_Queues.iactive_flag = 1 ;
>WHERE Trans.cResolution_Codes_Fk is NUll
>
>SELECT COUNT(cTrans_pk) FROM Queue_Names ;
>INNER JOIN trans_Employees_Queues ON Queue_Names.cQueue_Names_pk=Trans_Employees_Queues.cQueue_Names_fk ;
> INNER JOIN Trans ON Trans.ctrans_pk = Trans_Employees_Queues.ctrans_fk ;
> AND Trans_Employees_Queues.iactive_flag = 1 ;
>WHERE Trans.cResolution_Codes_Fk is NUll
>
Ok, I found that SELECT * FROM Trans_Employees_Queues WHERE cQueue_Names_fk NOT in (SELECT cQueue_Names_pk FROM Queue_Names) returns 826 records. So our last data load has a problem, which explains the difference in my statistical results.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform