Quote:
Originally Posted by r937
the reason is, the subquery is allowed to return only one column
you've got two
select * from dbo.nte21t_notetranpmt a
where a.pmt_id=(select pmt_id,max(prcs_dt) as maxn21t from dbo.nte21t_notetranpmt group by pmt_id)
|
how do i fix this cause when i remove pmt_id.. i get this error
"Msg 512, Level 16, State 1, Line 1
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
(0 row(s) affected)"