Alteryx Designer Desktop Discussions

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

How to Convert Sql function into Alteryx Desinger

Puneet13
8 - Asteroid

Help me develop below function into alteryx.

 

min(isNull(ltrim(rtrim(Website_Process)),''))

7 REPLIES 7
DataNath
17 - Castor

min(isNull(ltrim(rtrim(Website_Process)),''))

 

Hello @Puneet13, you'd first need to treat your field in a Formula tool. To recreate isNull(ltrim(rtrim(Website_Process)),'') you could use:

 

IIF(IsNull(Trim([Website_Process])),'',[Website_Process])

 

To perform aggregations in Alteryx, we need to use the Summarize tool. There you can just select the field of interest (Website_Process) and select Min. Full process here...

 

Starting data:

 

DataNath_0-1669028340129.png

 

Turning null values into nothing i.e. '':

 

DataNath_1-1669028358126.png

 

Finding the Min value:

 

DataNath_2-1669028371711.png

 

Now, if you want to find the minimum actual value then I'd filter out these empty values:

 

DataNath_3-1669028399326.png

 

 

And then perform the aggregation:

 

DataNath_4-1669028412472.png

 

As an off-topic note, please use the tags sparingly when creating threads - many of those used here are unrelated to the topic and will cause clutter in those areas!

Puneet13
8 - Asteroid

Fine to using above data, however i have multiple columns with it so how i will run with this together to impacting the other data

DataNath
17 - Castor

@Puneet13 not sure what you mean sorry? Are you able to provide a little snippet of data (even if it's just mocked up/dummy data) where you can show what you currently have and what you expect in the outcome.

Puneet13
8 - Asteroid

Puneet13_0-1669034415667.pngPuneet13_1-1669034452929.png

I want to say if i have multiple column with this variable to so how i can merge with the summarize tool which is not empty or summarize tool which is showing empty as per the minimum and how to get all variable with it.

DataNath
17 - Castor

@Puneet13 if I'm understanding your question right, then you just need to conduct a join on the min value being equal to the raw value that sits within the starting data set. Here you can see that I pull through 2 records for example, that match the 'empty' min value:

 

DataNath_0-1669040018784.pngDataNath_1-1669040027243.pngDataNath_2-1669040037440.png

Puneet13
8 - Asteroid

 Thanks for the Solution, one more function please help me to understand is this same as above one - isNull(min(ltrim(rtrim(P1))), '')

Puneet13
8 - Asteroid

Also in above snapshot which join I need to perform because it is showing huge amount of records around 18 crore in data we have only 10k records only and also in summarize min website process showing as blank it showing data.

 

Puneet13_0-1669110916466.png 

Puneet13_1-1669111123596.png

 

 

Labels