Let’s talk Alteryx Copilot. Join the live AMA event to connect with the Alteryx team, ask questions, and hear how others are exploring what Copilot can do. Have Copilot questions? Ask here!
Start Free Trial

Alteryx Designer Desktop Discussions

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

Weekday Function in excel

Alvin_C_Apostol
5 - Atom

Hi Everyone, 

 

Is there a way for me to do the operation below in alteryx?

 

so i have the computation below:

 

Alvin_C_Apostol_2-1600940653415.png

 

so the excel syntax is: =IFERROR($D2-(WEEKDAY($D2,2)-1),"""")

 

I am new in alteryx and I don't have an idea how to calculate it using alteryx

 

Hope someone can help me. 

 

thanks in advance 🙂

 

 

2 REPLIES 2
jdunkerley79
ACE Emeritus
ACE Emeritus

An equivalent expression would be:

 

 

DateTimeAdd([Date],1-ToNumber(DateTimeFormat([Date],"%u")),"days")

 

 

- DateTimeFormat([Date],"%u") will give you the WeekDay(,2) equivalent as a string

- ToNumber parses it to a number

- DateTimeAdd allows you to add a period to the date

 

Sample attached

 

Alvin_C_Apostol
5 - Atom

This works great thanks for your help! 

Labels
Top Solution Authors