1
Answer

aggregated is an outer reference.???

Vipin Mittal

Vipin Mittal

7y
792
1
Error on execution time
An aggregate may not appear in the WHERE clause unless it is in a subquery contained in a HAVING clause or a select list, and the column being aggregated is an outer reference.
Answers (1)
2
Manav Pandya

Manav Pandya

94 19.9k 2.3m 7y
Hello
 
I think you stuck at problem of date
 
Please attach query and find solution below , it wll surely help you :
https://blog.sqlauthority.com/2012/06/03/sql-server-fix-error-147-an-aggregate-may-not-appear-in-the-where-clause-unless-it-is-in-a-subquery-contained-in-a-having-clause-or-a-select-list-and-the-column-being-aggregated-is-an-outer-refer/
 
Thanks