A
Alex
I have the following expression in an update query. It works until I add
"IIf(([ExcelARefParts].[NPC]="")" which gives me a type conversion error
when importing. Is there a way to change the below code to look to see if
[ExcelARefParts].[NPC] is null? All my fields in the table and form have the
correct/matching data types. NPC is a number and NHL is text, Qty and QtyTop
are both number. Thanks.
IIf(IsNull([ExcelARefParts].[NPC]) And
([AllNewParts].[NHL]<>"Top"),[TargetNPCCost]*[AllNewParts].[Qty],IIf(IsNull([ExcelARefParts].[NPC])
And
([AllNewParts].[NHL]="Top"),[TargetNPCCost]*[AllNewParts].[QtyTop],IIf(([ExcelARefParts].[NPC]="")
And
([AllNewParts].[NHL]<>"Top"),([TargetNPCCost]*[AllNewParts].[Qty])-[ExcelARefParts].[NPC],([TargetNPCCost]*[AllNewParts].[QtyTop])-[ExcelARefParts].[NPC])))
"IIf(([ExcelARefParts].[NPC]="")" which gives me a type conversion error
when importing. Is there a way to change the below code to look to see if
[ExcelARefParts].[NPC] is null? All my fields in the table and form have the
correct/matching data types. NPC is a number and NHL is text, Qty and QtyTop
are both number. Thanks.
IIf(IsNull([ExcelARefParts].[NPC]) And
([AllNewParts].[NHL]<>"Top"),[TargetNPCCost]*[AllNewParts].[Qty],IIf(IsNull([ExcelARefParts].[NPC])
And
([AllNewParts].[NHL]="Top"),[TargetNPCCost]*[AllNewParts].[QtyTop],IIf(([ExcelARefParts].[NPC]="")
And
([AllNewParts].[NHL]<>"Top"),([TargetNPCCost]*[AllNewParts].[Qty])-[ExcelARefParts].[NPC],([TargetNPCCost]*[AllNewParts].[QtyTop])-[ExcelARefParts].[NPC])))