• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1122
  • Last Modified:

ERROR: The expression you entered has invalid vertical bars (|).

The formula

UOM:IIf ( [ARev Design]![CLASSIFICATION] ="COB" | "EA"| "MTR")

gives the error message

The expression you entered has invalid vertical bars (|).

Has anyone any idea what I have done wrong?
0
Zarbs
Asked:
Zarbs
1 Solution
 
Stephen_PerrettCommented:
replace vertical bars with commas i.e.    

UOM:IIf ( [ARev Design]![CLASSIFICATION] ="COB", "EA", "MTR")

Steve
   
0
 
ZarbsAuthor Commented:

FromUnit:  IIf ( [ARev Design]![CONSTRUCTION] ="COB" , "EA", "MTR")

Now the error is:
The expression you entered contains invalid syntax.
You omitted an operand or operator, you entered an invalid character or comma, or you entered text without surrounding it in quotation marks.
0
 
Stephen_PerrettCommented:
Try

FromUnit:  IIf ( [ARev Design].[CONSTRUCTION] ="COB" , "EA", "MTR")

Steve
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Rey Obrero (Capricorn1)Commented:
this should work, this is correct

FromUnit: IIf([ARev Design]![CONSTRUCTION]="COB","EA","MTR")

try it by creating a query

0
 
ZarbsAuthor Commented:

FromUnit:  IIf ( [ARev Design].[CONSTRUCTION] ="COB" , "EA", "MTR")

The expression you entered contains invalid syntax.
You omitted an operand or operator, you entered an invalid character or comma, or you entered text without surrounding it in quotation marks.
0
 
Stephen_PerrettCommented:
I tested you expression and it works without error with

!

 or

 .

Steve
0
 
Stephen_PerrettCommented:
I don't undestand why there appear to be gaps are showing in your expression

Where are you typing this expression?

Steve
0
 
Stephen_PerrettCommented:
Try deleting everything in the field or deleting the whole field altogether

and starting again

Sometimes you can get carriage return and or linefeed characters in the cell and you can't see what else is in there

Steve
0
 
ZarbsAuthor Commented:
I have used this expression hundreds of times in the past but it just won't work now.  
Something weird is happening and I can't figure it out.
0
 
ZarbsAuthor Commented:
I've worked it out.

A few days ago I changed the list seperator in regional settings for a CSV data extract where I wanted the delimiter to be a |.

After changing it back all ok.
0
 
DarthModCommented:
PAQed with points (500) refunded

DarthMod
Community Support Moderator
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now