B
bandblue
Hello,
I have a query that I am pulling out selective data from a string of a
part description. Here is the part description.
RESISTOR 0603 47KOHM,5%
Note the Field name is [ITEM_DESCRIPTION]
Here is my formula
Tolerance1:
IIf(InStr([ITEM_DESCRIPTION],"%")>0,IIf(Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-2,1)="
",Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-1,2),IIf(Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-2,1)=",",Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%"-1),2)
The formula works fine when referencing " " however the result is
#Error when I reference the comma ","
This happens in all cases where a comma is instead of a space. Any idea
on what I need to change? Thank you for your help
I have a query that I am pulling out selective data from a string of a
part description. Here is the part description.
RESISTOR 0603 47KOHM,5%
Note the Field name is [ITEM_DESCRIPTION]
Here is my formula
Tolerance1:
IIf(InStr([ITEM_DESCRIPTION],"%")>0,IIf(Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-2,1)="
",Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-1,2),IIf(Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%")-2,1)=",",Mid([ITEM_DESCRIPTION],InStr([ITEM_DESCRIPTION],"%"-1),2)
The formula works fine when referencing " " however the result is
#Error when I reference the comma ","
This happens in all cases where a comma is instead of a space. Any idea
on what I need to change? Thank you for your help