I'm trying to open a recordset using this query string:
SELECT [Field0] AS [Field0Description], [Field1] AS [Field1Description] FROM [TEMP_ExportQry] GROUP BY [Field0], [Field1] HAVING [UserID] = 6
but I get this error:
run time error 3122 - you tried to execute a query that does not include the specifiec expression [UserID]=6 as part of an aggregate function
the data is taken from the TEMP_ExportQry table and the UserID field is there.
if I remove the Having part all is OK.
SELECT [Field0] AS [Field0Description], [Field1] AS [Field1Description] FROM [TEMP_ExportQry] GROUP BY [Field0], [Field1] HAVING [UserID] = 6
but I get this error:
run time error 3122 - you tried to execute a query that does not include the specifiec expression [UserID]=6 as part of an aggregate function
the data is taken from the TEMP_ExportQry table and the UserID field is there.
if I remove the Having part all is OK.