Alteryx Designer Desktop Discussions

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

Using a variable in filter tool

reedy212
7 - Meteor

Looking for ways I can get a date range from a look up table then use those start and end dates in a filter.

 

In SQL I would 
declare @startdate date
Set @startdate = (Select startdate from Lookup where period=1)

 

then I could get data where date >@startdate 

 

 

Attached a pseudocode example.  

3 REPLIES 3
binuacs
20 - Arcturus

@reedy212 You can use the min and max of the field End_Date

binuacs_0-1686240938458.png

 

npariso
10 - Fireball

Hi @reedy212 the first thing you would need to do is append the user inputted dates for filter to the source data set.

 

The attached solution should accomplish what you are looking for. Let me know if not and we can rework it.

reedy212
7 - Meteor

I think this would work, but only for a limited set of analysis periods. My example was simplified, but fully fleshed out I would require the option to run the workflow with any analysis period for an entire year. Min and Max enddate wouldn't work for a middle of the year analysis period. 

Labels