Hi!
Can you tell me how I can convert a number to a string and back?
I take data from two sources, they are the same, but the type of value is different, so the equivalence check does not work.
Hi!
Can you tell me how I can convert a number to a string and back?
I take data from two sources, they are the same, but the type of value is different, so the equivalence check does not work.
Hey @a1ekseev!
Welcome to the n8n community!
You can convert a number to a string using the .toString() method. And to convert the string back to number you can use the parseInt() method.
In the workflow below, I am converting the number to a string, inside the Expression Editor. {{$node["Set"].json["value_number"].toString()}}
. This only converts the number to string for checking the values, and the original data type remains the same.
I hope this helps.
Now I understand the syntax.
Thank you!
Happy that I could help.
Have fun!