ALTERYX INSPIRE | Join us this May for for a multi-day virtual analytics + data science experience like no other! Register Now

Alteryx Designer Ideas

Share your Designer product ideas - we're listening!
Submitting an Idea?

Be sure to review our Idea Submission Guidelines for more information!

Submission Guidelines

Allow temporary local variables in formula tools

It would be useful to allow for temporary local variables in formula tools. This could make code shorter, better readable, easier to maintain and help to avoid auxiliary columns which have to be deleted afterwards.

 

Arbitrary example for illustration:

if Length([Col1] + [Col2] + [Col5]) > 50 then
    Left([Col1] + [Col2] + [Col5], 48) + "..."
else
    [Col1] + [Col2] + [Col5]
endif

versus

tmpstr = [Col1] + [Col2] + [Col5]
if Length(tmpstr) > 50 then
    Left(tmpstr, 48) + "..."
else
    tmpstr
endif

The idea is that the temporary variable has limited validity inside the formula for a specific cell.

 

2 Comments
patrick_digan
16 - Nebula
16 - Nebula

@haraldharders Really interesting idea. @jdunkerley79 's alteryx abacus would allow something similar to what you're after. It would be great if they could build something like this into the product itself without having to use a third party addin.

 

if Length(VarTextWrite("tmpstr",[Col1] + [Col2] + [Col5])) > 50 then
    Left(VarTextRead("tmpstr"), 48) + "..."
else
    VarTextRead("tmpstr")
endif

 

CristonS
Alteryx Community Team
Alteryx Community Team

hi @haraldharders, thanks for your idea! I have definitely found myself wanting the same thing at times. We’re doing our best to ensure all product ideas are reviewed and commented on by Alteryx when the necessary criteria are met. Be sure to check out our updatedSubmission Guidelines for any board or criteria related questions!