I'm trying to de-duplicate records by a particular field. I'm getting an error when I try a GROUP BY in my query.
An error occurred while checking the query syntax. Errors: Column 'C7226490.MyDataExt.FieldOne' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
This is the query I used:
SELECT FieldOne, FieldTwo, COUNT(FieldThree) FROM MyDataExt GROUP BY FieldOne
Does anyone know why I can't use this GROUP BY query? The error does go away if and only if I put every single field that I used in my SELECT into the GROUP BY. That, however, is not what I want. And I'm not certain why my COUNT() isn't being recognized as an aggregate.