Early bird tickets for Inspire 2023 are now available! Discounted pricing closes on January 31st. Save your spot!

Alteryx Designer Discussions

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

Formula Error: The field "" is not contained in the record

8 - Asteroid

Hello community. I'm trying to do something very simple, if a field is null, I want to replace is with the values from 2 other fields. I receive the following error:  The field "" is not contained in the record.


Here's the expression:


IF IsNull([EXT_TRADE_ACCT_NBR         ])

THEN [ID2        ], [ID]

ELSE "ok"



Thanks for your help!

14 - Magnetar


Based on this formula, I'm not 100% sure whether you want to replace the value with a combined version of the two other fields, or if you want to replace with ID2, and if there is no ID2, use ID instead.

I wrote up a revised formula for each of these options.  Let me know if this matches your expectation, or if there is something else you are trying to do!


//Combines ID2 and ID

IF IsNull([EXT_TRADE_ACCT_NBR         ])

THEN [ID2        ]+ [ID]

ELSE "ok"

//Chooses ID2, and defaults to ID if it is null

IF IsNull([EXT_TRADE_ACCT_NBR         ])

            IF ISNULL([ID2        ])
            THEN [ID]
            ELSE [ID2        ]
ELSE "ok"

8 - Asteroid

Thank you for your reply!  I am trying to combine ID2 and ID if the value is null, so your first example below is very helpful. Even using the plus sign (great suggestion!), I still receive the error message. Do you have any additional advice? Thank you.



7 - Meteor

And 'The field "" is not contained' error might be because you have not selected a field in the formula tool or a name is not given to the new field

8 - Asteroid

I figured it out! Problem solved by reformatting the output column name.  :-)

6 - Meteoroid

this helped me. i had my formula right but i missed entering the new column name. it gave me the error. after i gave it a column name, the error went away. 

5 - Atom

I ran into a similar issue. The problem was not the formula. The problem was I inadvertently had an output column with no name and a space in the formula box(see attached BMP). It was minimized so I didn't see it for a bit.