Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL Select in SQL Server
Message
De
14/06/2004 16:01:18
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Titre:
SQL Select in SQL Server
Divers
Thread ID:
00913605
Message ID:
00913605
Vues:
59
Hi all ,

How can i convert this SQL statement to work with SQL Server,
SELECT * , SUM(b.Quantidade) as QUANT;
	FROM FICCARC a ;
	LEFT OUTER JOIN FICCARL b ;
	ON a.encomenda = b.encomenda ;
	LEFT OUTER JOIN FICMOLDE c ;
	ON a.terceiro = val(c.molde) ;
	WHERE a.encomenda=VAL(thisform.ncarga) ;
	GROUP BY b.Material ;

Error:
is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
If a put in the select one date field and in group the same field the sum is done by DATE and not by all records.

João Batista
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform