Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Invalid in the select list

Author  Topic 

zhshqzyc
Posting Yak Master

240 Posts

Posted - 2009-02-25 : 20:23:58
Column 'TENDER.TND_DESCR' is invlid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.


select
RegID = 'ALL',
RptGrp = 1,
GrpName = '',
ColName = T.TND_DESCR,
subColAmt =null,
subColCount =null,
ColAmt=isnull(sum(L.TND_ACCM_AMT),0) ,
ColCount=isnull(sum(L.TND_TRAN_CNT),0),
EmpID ='ALL'
from TENDER T inner join TILL_TND_CUR L
on T.TND_CD = L.TND_TYP_CD and T.STR_ID = L.STR_ID

Thanks for digging this bug.

robvolk
Most Valuable Yak

15732 Posts

Posted - 2009-02-25 : 20:30:02
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=120577
Go to Top of Page
   

- Advertisement -