Multiplying a column when record does not appear on a separate table
Hello,
I would like to multiple a column by a % unless a corresponding record is located in a separate table. For example, in the attached database, the query multiplies the entire Item Table by 90%. I would like for the query to not apply the 90% to Item# 2 since it appears on the Nondiscount Table. The expected output should appear as below, where all values are multipled by 90% (Expr1) except record 2.
SELECT
[Item Table].[Item#],
[Item Table].Value1,
CCur(Nz([NonDiscount Table]![Value1],[Item Table]![Value1]*0.9)) AS NewValue
FROM
[Item Table]
LEFT JOIN
[NonDiscount Table]
ON [Item Table].[Item#] = [NonDiscount Table].[Item#];
/gustav