In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Update Value with Formula

swhitmeyer
8 - Asteroid

Hi, I am getting a parse error when I am trying to update this formula (\2017\03-March\VALIDATE CASH 03-31-2017.xlsm)  into Alteryx Action tool- see formula below.

 

"\"+tostring([#1])+"\"+tostring([#2])+"\VALIDATE CASH "IF +tostring([#3])+ = ‘Q1’ THEN ‘03-31’ ELSEIF +tostring([#3])+ = ‘Q2’ THEN ‘06-30’ ELSE ‘ERROR’ ENDIF"-"+tostring([#1])+".xlsm|CMLReinsured $"

 

13 REPLIES 13
swhitmeyer
8 - Asteroid

That worked, thank you so much!!!

swhitmeyer
8 - Asteroid

Even more complicated, getting an invalid type in subtration operator

 

 

"\\mmdata3b3r\REINS\Palm\"

+ IF tostring([#2]) = "Q1" THEN tostring([#1])-1 ELSE tostring([#1]) ENDIF +

"\"

+ IF tostring([#2]) = "Q1" THEN "12-December" ELSEIF tostring([#2]) = "Q2" THEN "03-March" ELSEIF tostring([#2]) = "Q3" THEN "06-June" ELSEIF tostring([#2]) = "Q4" THEN "09-September" ELSE "ERROR" ENDIF + "

\WiltonRe Reserves_"

+ IF tostring([#2]) = "Q1" THEN "Dec" ELSEIF tostring([#2]) = "Q2" THEN "Mar" ELSEIF tostring([#2]) = "Q3" THEN "Jun" ELSEIF tostring([#2]) = "Q4" THEN "Sep" ELSE "ERROR" ENDIF + "

+ IF tostring([#2]) = "Q1" THEN Right([tostring([#1])-1],2) ELSE Right([tostring([#1])],2) ENDIF +"

.xlsx"

Joe_Mako
12 - Quasar

What are the "-1" operations you are attempting? What are some potential values of [#1] and [#2]?

 

"\\mmdata3b3r\REINS\Palm\"+
IF tostring([#2]) = "Q1" THEN tostring(ToNumber([#1])-1)
ELSE tostring([#1]) ENDIF +
"\"+
IF tostring([#2]) = "Q1" THEN "12-December"
ELSEIF tostring([#2]) = "Q2" THEN "03-March"
ELSEIF tostring([#2]) = "Q3" THEN "06-June"
ELSEIF tostring([#2]) = "Q4" THEN "09-September"
ELSE "ERROR" ENDIF +
"\WiltonRe Reserves_"+
IF tostring([#2]) = "Q1" THEN "Dec"
ELSEIF tostring([#2]) = "Q2" THEN "Mar"
ELSEIF tostring([#2]) = "Q3" THEN "Jun"
ELSEIF tostring([#2]) = "Q4" THEN "Sep"
ELSE "ERROR" ENDIF +
IF tostring([#2]) = "Q1" THEN Right(tostring(ToNumber([#1])-1),2)
ELSE Right(tostring([#1]),2) ENDIF +
".xlsx"

swhitmeyer
8 - Asteroid

In the first IF statement I am trying to take a year for example 2017 and minus one for PY.

 

In the third statement I am trying to take the year so it is 17 or 16.

Labels
Top Solution Authors