Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL COUNT Question
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01223186
Message ID:
01223193
Vues:
14
It gives me
"Function name is missing )."



>Try
>
>SELECT mh.Caption, mh.Icon, ;
>          (SELECT COUNT(*) FROM MenuItems mi WHERE mi.Parent = mh.id) AS Total ;
>	FROM MenuHead MH;
>	INTO CURSOR Temp1
>
>
>>I have a header table and a child table.
>>
>>Not all header records have a child record.
>>
>>I want to pull all headers and also a column with the count of child records.
>>
>>What I have isn't working. Using VFP 9:
>>
>>
>>SELECT mh.Caption, mh.Icon, COUNT(mi.*) AS Total;
>>	FROM MenuHead MH;
>>	JOIN MenuItems mi on mi.Parent = mh.id;
>>	GROUP BY mh.Caption, mh.Icon;
>>	INTO CURSOR Temp1
>>
>>
>>Anyone?
>>
>>Thanks
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform