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

Parse Error

kimberly_meyer
5 - Atom

Hi,

I get the "Parse Error at char (0): Type mismatch in operator +. (Expression #1). Should I be using the Formula when I'm trying to concatenate?  Please help! Thanks!

 

7 REPLIES 7
AkimasaKajitani
17 - Castor
17 - Castor

Hi @kimberly_meyer 

 

The error is caused by that the data type is not correct.

I think you are trying to concatenate numeric type data as a string.

Please add the ToString function.

 

ToString([PO Number])+ToString([PO Line Number])

 

AngelosPachis
16 - Nebula

Hi @kimberly_meyer ,

 

Your expression looks correct and yes you should be using the formula when you are trying to concatenate. 

 

Can you check that both fields are of string data type?

 

If they are not then maybe you can wrap each one of them with a Tostring formula, so your expression would be

 

Tostring([PO Number])+Tostring([PO Line Number])

 

Hope that helps,

 

Angelos

aluthra
8 - Asteroid

Hi @kimberly_meyer,

 

Make sure that both columns are string data type and it should work

 

Thanks,

Amit

kimberly_meyer
5 - Atom

Thank you all!  It works now!

kimberly_meyer
5 - Atom

So, I have another parse error and I tried using the Tostring....any thoughts as to how to fix this one?

Luke_C
17 - Castor

Hi @kimberly_meyer 

 

In this case you appear to be doing a mathematical operation rather than concatenation, so you would not use the tostring function because you can't perform math on strings, only numbers. If you still have an error after removing the tostring functions, try using 'tonumber' instead. You may also want to change the data type of the new field to be numeric.

kimberly_meyer
5 - Atom

Thank you!!

Labels