Free Trial

Alteryx Designer Desktop Discussions

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

Something missing in formaula

Kamran1991
11 - Bolide

if [Fun Score]<1 then "LIFE CHANGING!" elseif
if [Fun Score]>1 then "AMAZING" elseif
if [Fun Score]>2 then "Great!" elseif
if [Fun Score]>3 then "Fun" elseif
if [Fun Score]>4 then "Pretty Good" elseif
if [Fun Score]>5 then "Feeling Weird" elseif
if [Fun Score]>6 then "Dizzy" elseif
if [Fun Score]>7 then "Sick" elseif
if [Fun Score]>8 then "Really Sick" else
"Refund" endif

 

Can anyone let me know what is wrong in this formula ?

 

Thanks,

Kamran

10 REPLIES 10
ShankerV
17 - Castor

Hi @Kamran1991 

 

Could you please remove the extra if added after each ELSEIF.

 

Many thanks

Shanker V

ShankerV
17 - Castor

Hi @Kamran1991 

 

The below will work for you.

 

if [Fun Score]<1 then "LIFE CHANGING!"

elseif [Fun Score]>1 then "AMAZING"

elseif [Fun Score]>2 then "Great!"

elseif [Fun Score]>3 then "Fun"

elseif [Fun Score]>4 then "Pretty Good"

elseif [Fun Score]>5 then "Feeling Weird"

elseif [Fun Score]>6 then "Dizzy"

elseif [Fun Score]>7 then "Sick"

elseif [Fun Score]>8 then "Really Sick"

else "Refund"

endif

 

Note: Make sure the column [Fun Score] is of numeric datatype. Else we need to use [Fun Score] > "1", all the values should be within ""

 

Many thanks

Shanker V

Kamran1991
11 - Bolide

I have tried all the logics but not working out.

FinnCharlton
13 - Pulsar

@Kamran1991 What error message are you getting? Even better if you could share a sample workflow with us to take a look at.

Kamran1991
11 - Bolide

Having tried all the logics and applications, I am totally exhausted now therefor shut the task up.

mceleavey
17 - Castor
17 - Castor

@Kamran1991 ,

 

as @FinnCharlton requested, can you let us know what's wrong?

The first post simply had an Elseif followed by an IF, which would error. After that was solved, can you let us know what the new error is?

 

 

M.



Bulien

Kamran1991
11 - Bolide

Error message is attached here,

 

Thanks,

Kamran

FinnCharlton
13 - Pulsar

Hi @Kamran1991 , there is still something wrong with your IF statement, have you tried @ShankerV's solution above? If this still doesn't work, please could we see a screenshot of the formula and we should be able to fix it

Rana_Kareem
9 - Comet

Hi @Kamran1991 ..

 

What's the data type of Fun Score?

It must be Double or Float

Labels
Top Solution Authors