I have a workflow where I need to change the current name in a field to another name if the condition is met. I have the formula set up, but when I run my workflow, it does not replace the old name with the new. Any ideas on what I am doing wrong? This is not the real scenario, just an example.
Solved! Go to Solution.
@dngnc7 Without the dataset and workflow itself, it is hard to say.
I would look at the datatypes of the columns you have included. Is ColumnA not a string type but you are looking for a string, if so you would just need to throw a ToString() in front of ColumnA within the formula and it would work.
Again, hard to really diagnose without seeing the workflow and error itself.
EDIT: I realize these probably aren't real columns which is why the screenshot shows an error, @alexnajm's solution is definitely on the right track.
Bacon
This is correctly constructed syntax-wise although odd because it won't do anything - this tells me if the value in column a equals “dog”, then replace any instance of “animal” with “pet”, otherwise leave it alone. It is not going to do anything since you’re asking it to look for a “dog”, but you want to replace “animal”.
can you provide proof of your formula not working? Maybe this is what you want, to replace "Dog" with "Pet"?
IF [ColumnA]="Dog" THEN Replace([ColumnA], "Dog", "Pet") ELSE [ColumnA] ENDIF
Maybe you don’t have have Dog as a stand alone. You need CONTAINS([ColumnA],”Dog”) then continue your IF statement rather than [ColumnA] = “Dog”.
Also, case sensitive! You can either use UpperCase(), LowerCase(), or TitleCase() to standardize.
User | Count |
---|---|
63 | |
28 | |
23 | |
23 | |
22 |