Alteryx Designer Desktop Discussions

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

Auto Field Tool & Select Tool Conundrum

pyalx
6 - Meteoroid

Hello,

 

What exactly does the Alteryx Auto Field / Select Tool do?

 

I read a document from Smartsheet.

 

Case scenario #1: it automatically coverts values such as 1235abc into NULL and only keep values that does not have characters (all numeric)

 

OLD COLUMN ROWS

123

122ccd

332

 

NEW COLUMN ROWS

123

NULL

332

 

 

Case scenario #2: it automatically coverts values such as 1235abc into 1235 

 

 

OLD COLUMN ROWS

123wqq

122ccd

332_ret

 

 

NEW COLUMN ROWS

123

122

332

 

 

the difference between case #1 and case #2 is that case #2 has a character appended on all values of row.

 

Does anyone know what exactly or "could be" happening?

3 REPLIES 3
cjaneczko
13 - Pulsar

The Auto Field resizes the incoming field, it shouldnt be adding any NULL values. Itll look at the largest value in the field and resize it to that value. By default I think strings come in at 254 characters, but if the largest value has 10 characters, it will resize all of them from 254 down to 10. And the Select tool lets you change the field type and deselect fields you dont want to use or pass through the workflow. Is there another tool you may be using in your workflow thats causing fields to be NULL or drop characters off?

martinding
13 - Pulsar

Hi @pyalx,

 

The Auto Field tool takes in "String" type fields and automatically determines the data type and size for each of those fields. Auto Field doesn't turn values into Nulls.

 

So in your scenario, the nulls have to be caused by a downstream tool. 

 

Note that Auto Field is convenient, but has its pitfalls.

For example, let's say your data is like this:

Column 1
123a
123
123b

 

Using Auto Field, this field will be turned into Type: String, Size 4, since the longest string is of 4 characters here.

 

And then if you do some operations later, let's say using a formula tool to update everything in Column 1 to "Today".

 

What you will get will not be Today (because it is 5 characters long), you will end up getting:

Column 1
Toda
Toda
Toda

 

So it is best to use a Select Tool and explicitly specify your data type and size if you can.

 

Within the Select Tool, you can save or load a previous configuration, and this is can be a convenient choice if you work with the same incoming data over time.

martinding_0-1681422645453.png

 

RobertOdera
13 - Pulsar

HI, @pyalx 

 

In Alteryx Designer:

 

Right-click on the tools you mention --> Open Example.

This will give you the most empirical explanation of what is possible/ happening.

Cheers.

Labels