Could someone explain why?

  • Thread starter Thread starter WebRaster
  • Start date Start date
W

WebRaster

Could someone explain why this SELECT produce an error message ?


SELECT cc_nome, count(incc) as tot, incc
FROM conta_ea GROUP BY cc_nome
ORDER BY cc_nome ASC;

----------------------------------------------------------------------------
 
WebRaster said:
SELECT cc_nome, count(incc) as tot, incc
FROM conta_ea GROUP BY cc_nome
ORDER BY cc_nome ASC;
Microsoft OLE DB Provider for ODBC Drivers error "80004005'

What is conta_ea? I suspect it is a table that is corrupt, or is
reachable over ODBC only and an error occurs there.
 
Hi,


Because incc, the third item in the SELECT clause, is neither GROUP BY
neither aggregated.


SELECT cc_nome, COUNT(incc) As Tot
FROM contra_ea
GROUP GY cc_nome
ORDER BY cc_nome ASC;


should do.




Hoping it may help,
Vanderghast, Access MVP
 
Back
Top