>  nullIf(docunitprice * orderqty)

This where the error appears to be.  The SQL NULLIF() function takes
two parameters and returns NULL if the values of the two parameters
match.  In this case, I assume you want to return NULL if
(docunitprice * orderqty) equals zero, so you would change this to be
nullIf(docunitprice * orderqty, 0) to get a proper comparison.


-Justin Scot

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: http://www.houseoffusion.com/groups/sql/message.cfm/messageid:3434
Subscription: http://www.houseoffusion.com/groups/sql/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/sql/unsubscribe.cfm

Reply via email to