Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Group by clause error in sql with NO group by clause
Message
De
19/06/2003 13:22:01
 
 
À
19/06/2003 04:36:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00801354
Message ID:
00801844
Vues:
28
Hi Fabio,

>Hi Aleksey,
>
>the two select are not equal.
>
>
>CREATE CURSOR TEST (i1 I,i2 I,y Y)
>INSERT INTO TEST VALUES(1,2,$10)
>INSERT INTO TEST VALUES(2,1,$10)
>INSERT INTO TEST VALUES(2,1,$10)
>INSERT INTO TEST VALUES(1,2,$10)
>
>SELECT i1+i2 total,SUM(y) sumGroup FROM TEST GROUP BY i1,i2
>
>SELECT i1+i2 total,SUM(y) sumGroup FROM TEST GROUP BY total
>
Did I say that they are equal? I don't think so. I just said they are syntactically correct.





>
>SELECT i1+i2 total,SUM(y) sumGroup FROM TEST GROUP BY total
>
>is not valid on MSQL, on MSQL equivalent expression is
>
>SELECT i1+i2 total,SUM(y) sumGroup FROM TEST GROUP BY i1+i2
>

Does it have anything to do with SQL syntax supported by VFP?

Thanks,
Aleksey.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform