Alteryx Designer Desktop Discussions

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

Identify last letter is string or number

sneha_bhiwagade1
8 - Asteroid

Hi Team,

 

Could you please help me to get the desired output

 

whenever the last letter in the input is alphabet I would like to replace it with zero

 

Many Thanks in advance!!

 

InputOutput
A1234DA12340
B1968AB19680
C0659EC06590
D0874dD08740
E02540E02540
4 REPLIES 4
binuacs
21 - Polaris

@sneha_bhiwagade1 one way of doing this

image.png

ChrisTX
16 - Nebula

Try this in a Formula tool:

 

IF Uppercase(Right([Original value], 1)) >= "A" and
     Uppercase(Right([Original value], 1)) <= "Z"
THEN
Substring([Original value],0,Length([Original value]) - 1) + "0"
ELSE [Original value]
ENDIF

 

Screenshot 2024-09-24 053930.png

 

 

Check out all functions here: https://help.alteryx.com/current/en/designer/functions.html

 

Chris

NidhiSethi
6 - Meteoroid
 

A sample way to achieve the output. 

sneha_bhiwagade1
8 - Asteroid

Thank You @binuacs 

Polls
We’re dying to get your help in determining what the new profile picture frame should be this Halloween. Cast your vote and help us haunt the Community with the best spooky character.
Don’t ghost us—pick your favorite now!
Labels