MS Access query failing in ODBC

  • Thread starter Thread starter Ash
  • Start date Start date
A

Ash

I have an access application in which all the database
tables are of "Linked Access" type. We are migrating
database from Access 2000 to SQLServer2000. So all the
tables are now connected to SQL database thru ODBC-"Linked
ODBC". This causes some of the queries failing. For
example the following query is failing with the error
message --"Group By Expressions must refer to column names
that appear in the select list" -- "TRANSFORM Count
(Events.EventKey) AS [The Value] SELECT
IndividualsNameIndex.IndividualName AS SpeakerName,
Events.EventSpeakerKey, Clients.ClientKey,
Clients.ClientName FROM (Clients INNER JOIN Products ON
Clients.ClientKey = Products.ClientKey) INNER JOIN (Events
INNER JOIN IndividualsNameIndex ON Events.EventSpeakerKey
= IndividualsNameIndex.IndividualKey) ON
Products.ProductKey = Events.EventProductKey WHERE
(((Events.EventSpeakerKey)>0)) GROUP BY
IndividualsNameIndex.IndividualName,
Events.EventSpeakerKey, Clients.ClientKey,
Clients.ClientName PIVOT "NumberOfEvents";".
 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

That error occurs in SQL server; therefore, it would appear that your
query is a pass-thru query or a View. Correct? If so, change it to a
regular Access query (in query design view: Query > Cross Tab Query).

FYI, CrossTab queries do not work in SQL server.


MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQEONoIechKqOuFEgEQKzCwCgsgzop3KvX2ytWyDXPnz8QYVTblgAn00n
ny7UqOnFyjDKhwYsDqfHBscm
=YYBq
-----END PGP SIGNATURE-----

I have an access application in which all the database
tables are of "Linked Access" type. We are migrating
database from Access 2000 to SQLServer2000. So all the
tables are now connected to SQL database thru ODBC-"Linked
ODBC". This causes some of the queries failing. For
example the following query is failing with the error
message --"Group By Expressions must refer to column names
that appear in the select list" -- "TRANSFORM Count
(Events.EventKey) AS [The Value] SELECT

< snip >
 
Back
Top