Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Despite the error, the date is converted correctly

Gromah
5 - Atom

Hi,

 

I need a little help. Can someone point me to the error in Formula Tool that causes the following message?

 
 
 

Zrzut ekranu 2024-11-20 135154.png

 

Despite the error, the date appears to be converted correctly.

 

Zrzut ekranu 2024-11-20 135349.png

 

Thanks!

1 REPLY 1
ChrisTX
16 - Nebula
16 - Nebula

I think the error comes from the BOOL part of your IIF function

 

I only use IIF for very simple expressions

 

Try this:

 

IF Contains([CPUDTE], "-")
THEN DateTimeParse(tostring([CPUDTE]),"%Y-%m-%d")
ELSE DateTimeParse(tostring([CPUDTE]),'%Y%m%d')
ENDIF

 

 

Chris

Labels
Top Solution Authors