Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Error: Formula (18): The field "" is not contained in the record. (Expression #1)

bcampbell0621
8 - Asteroid

 

Hello All:

 

This error is returned when I run my code in the formula part of the workflow.  

 

The offending code is as follows:

 

IF [BN] = "111111" THEN

[SBN] = "222222,333333"

ELSE

"Do Nothing"

ENDIF

 

BN and SBN are strings, but carry numeric values in this case.

13 REPLIES 13
TomWelgemoed
12 - Quasar

Another point - you cannot assign the value to a different field like you're doing in your formula (i.e.SBN= <value in the THEN statement).

 

You have to select the field (SBN) as per my example and then say the value (as I wrote it). 

bcampbell0621
8 - Asteroid

I think were I was unclear was that when BN = "11111" it represents a unique identifier that points to a specific individual. If that is true and BN = "11111" then I want to assign "22222,33333" to the SBN field of that individual.  

 

I apologize that I did not communicate that accurately.  

KP_DML
8 - Asteroid

Hello,

The Output Column (red arrow) is the "assignment field." The formula only contains the logic, not the assignment.

 

FormulaTool.png

 

 

TomWelgemoed
12 - Quasar

Morning @bcampbell0621 ,

 

My gut is that you are looking in the wrong place for the issue - if you're getting the error above, it means you're not telling Alteryx which field to put the formula into. I tried to simulate it in this example below - you simply have to create a new field (give it a new name by saying Add Column) or to select an existing one.

 

Formula error.png

 

Also, once you have done that, a pointer on the formula: you cannot assign values to different fields in the same calculation. You have to individually select each field you want to change and what the associated formula is. Hence you can't do SBN= Value. But fear not, Alteryx is great at letting you refer to changed values in the column next to it, so you can do something like I've done in this example below, where you Create "NewField" that is based on the updated results in column SBN. 

 

So in short, I would 1st update column SBN based on column BN and then if you wanted to store the results in another column, do a formula for that column. Hope that helps.

 

Best,

Tom

Formula  error 2png.png

 

Labels