Microsoft
Software
Hardware
Network
Question : sql question
I have this section in my sql script:
ISNULL(lot_loc.unit_cost, item.avg_u_cost) as [Unit Cost]
it works very well but in some cases lot_loc also = 0.0 in which case I'd also like it to pull the value from item.avg_u_cost.
How can I do this?
Answer : sql question
use this instead of the above
case when lot_loc.unit_cost is null or lot_loc.unit_cost =0 then item.avg_u_cost ELSE lot_loc.unit_cost END as as [Unit Cost]
Random Solutions
DoCmd.OpenForm Question
PHP write permissions
IE 6 Close "memory could not be read" error
Outlook Disconnected
Multiple Criteria in Query
Accessing Notes Items in Domino with VB.NET
How do I convert a stored procedure to be used for batch processing?
Can you install Vista / windows 7 to winnt directory
Way to change a SQL 2005 key
Internet Explorer very slow to respond and continually accesses floppy drive