Free Trial

Alteryx Designer Desktop Discussions

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

Malformed function call error

hegdepavithra10
9 - Comet

if [Right_RecordID] = 8 then
if ToNumber([A]) = ToNumber([Row-1:A])+ToNumber([Row-6:A] AND ToNumber(TrimRight(ToString([A]),"%"))>=10 then "Pass"
elseif ToNumber([A]) = ToNumber([Row-1:A])+ToNumber([Row-6:A] and ToNumber(TrimRight(ToString([A]),"%"))<10 then "Threshold Breach"
elseif ToNumber([A]) != ToNumber([Row-1:A])+ToNumber([Row-6:A] and ToNumber(TrimRight(ToString([A]),"%"))>=10 then "Exception"
else "Threshold breach & Exception" ENDIF

 

when using the above formula in multi row formula I am getting the malformed function call error. In a column A. in row 8 the value needs to checked for2 conditions.

1. If it is greater than 10%

2. if it is a sum of row-1 and row-6

There are 4 conditions based on combinations

13 REPLIES 13
hegdepavithra10
9 - Comet

@atcodedog05  This does not seem to be adding decimal values correctly.

 

I tried the same formula that you have given. When i try to exceute it for the following data , it shows up as exception and not pass.

 

hegdepavithra10_0-1606417157057.png

 

I have tried converting the row 2 and row 7 into ToNumber(TrimRight(ToString([A],"%") as well. But its not adding up the numbers correctly. Could you please help?

atcodedog05
22 - Nova
22 - Nova

Hi @hegdepavithra10 

 

It had some issues. Fixed with a workaround. A single muti-row formula tool was not enough.

 

Here is a workflow for the task.

Output:

atcodedog05_0-1606418674391.png

Workflow:

atcodedog05_1-1606418700947.png

Hope this helps 🙂 Feel to ask if you have any questions


If this post helps you please mark it as solution. And give a like if you dont mind 😀👍

hegdepavithra10
9 - Comet

Hi @atcodedog05 

 

But isnt this essentially same as using ToNumber(TrimRight(ToString([A]),"%")) = ToNumber(TrimRight(ToString([Row-1:A]),"%"))+ToNumber(TrimRight(ToString([Row-6:A]),"%")) across the multirow formula?

 

The reason i am asking is , in my requirement i have 6 columns for which i am performing the multirow formula, so i have 6 multi formula added already. Just trying to make it concise if possible. 

 

I also happened to do one thing. I rounded off the value to 1 decimal value in the preceeding formulas and when i added multi row formula like the one you suggested earlier, it calculated it correctly.

atcodedog05
22 - Nova
22 - Nova

Hi @hegdepavithra10 

 

I tried to do it with single tool. There were some issues. And lot of ToNumber() and ToString() function in sync.

 

Hence i went with this approach.

 

FYI Muti-Row formula is not that flexible for writing multiple nested formulas 😅

I am not saying its impossible its just not flexible since debugging is not easy😅

 

One issue i found was you need to use Trim([A],"%") everywhere you are using it which was missing. And rounding also does help.

 

And you were able to build a workflow that worked correctly thats amazing 🙂

Labels
Top Solution Authors