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)
 Works in Query designer but not in trigger

Author  Topic 

walank
Starting Member

12 Posts

Posted - 2009-07-04 : 11:46:16
In Query designer this works fine:

DECLARE @posted_amount as float
SELECT @posted_amount=SUM(ardetail.PaymentsTo) FROM ardetail


but in a TRIGGER I'm getting error:
An expression of non-boolean type specified in a context where a
condition is expected, near 'SELECT'.

What's wrong ?

Thanks,

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-07-04 : 12:07:12
Can you show more code please?
I cannot see any mistake.

Fred


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

walank
Starting Member

12 Posts

Posted - 2009-07-04 : 12:33:19
Hm... today is working....
I should have rebooted my comp yesterday.

Thanks for help anyway
Go to Top of Page

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-07-04 : 13:33:47
Fine, when it is working


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -