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
stopping excel flickering
Connect to a Crosstab query in Access from Excel
Access 2003 on a Win2k PC. "Your Microsoft office Access database contains a missing or broken reference to the file DAO360.dll version 5.0
Dead Motherboard, anyway to migrate printers from one XP machine to another
sql
Mailbox unavailable. The server response was: 5.7.1 Unable to relay
error saying 'External table is not in the expected format.' when trying to update database from a dataset
Sorting by Activity Date in Ascending Order
Importing mmf file into Outlook
Date Comparison in MSSQL