In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

I have to back by subtracting it

Sshasnk
8 - Asteroid

So Basically I have to take the date which is 366 days from below given date

 

Example:

 

Date
31/12/2022

Date2 = Date - 366

 

Output

DateDate2
31/12/202231/12/2021
6 REPLIES 6
ChrisTX
16 - Nebula
16 - Nebula

Try a Formula tool with:   DateTimeAdd([your date], -366, "days")

 

Here's a list of all functions: Functions | Alteryx Help

 

Chris

binu_acs
21 - Polaris

@Sshasnk 

binuacs_0-1671110253775.png

 

ShankerV
17 - Castor

Hi @Sshasnk 

 

One way of doing this.

 

ShankerV_0-1671111587843.png

 

If this helps, please like this post and mark it as a solution. If you have any other questions, please let us know.

 

Many thanks

Shanker V

 

 

ShankerV
17 - Castor

Hi @Sshasnk 

 

Step 1: Input

ShankerV_0-1671111677509.png

 

Step 2: DateTime tool, as 31/12/2022 is not alteryx date format. Wanted to convert to YYYY/MM/DD.

ShankerV_1-1671111709713.png

 

Step 3: Formula tool

DateTimeAdd([Date1A], -366, "days")

 

ShankerV_2-1671111756750.png

 

Step4: Select tool to format the output

ShankerV_3-1671111790590.png

 

Output:

ShankerV_4-1671111806963.png

 

 

If this helps, please like this post and mark it as a solution. If you have any other questions, please let us know.

 

Many thanks

Shanker V

ShankerV
17 - Castor

hi @Sshasnk 

 

One more way to reach the exact output as you are expecting.

 

Output

DateDate2
31/12/202231/12/2021

 

ShankerV_0-1671112156581.png

 

 

If this helps, please like this post and mark it as a solution. If you have any other questions, please let us know.

 

Many thanks

Shanker V

ShankerV
17 - Castor

@Sshasnk 

 

Step 1: Input

ShankerV_0-1671112220201.png

 

Step 2: DateTime tool

ShankerV_1-1671112249123.png

 

Step 3: Formula tool

ShankerV_2-1671112263074.png

 

Step 4; Select tool

ShankerV_3-1671112294119.png

 

 

Step 5: Text to columns tool

ShankerV_4-1671112323061.png

 

Step 6; Formula tool

[3]+"/"+[2]+"/"+[1]

 

ShankerV_5-1671112344445.png

 

Step 7: Select tool

ShankerV_6-1671112371627.png

 

If this helps, please like this post and mark it as a solution. If you have any other questions, please let us know.

 

Many thanks

Shanker V

 

 

 

 

Labels
Top Solution Authors