Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

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

Start Time and End Time from a data set

udles5666
8 - Asteroid

Hi Community

 

I tried to use Min & Max function of Summary tool in the attached workflow but it doesn't seem to work. 

 

I am looking for the below output from the data set but not sure why Min & Max does not work the way I think it should. 

 

Can someone please have a look and help? Thanks,Start and End time.JPG 

5 REPLIES 5
Emil_Kos
17 - Castor
17 - Castor

Hi @udles5666,

 

Please verify if that is exactly what you need but I think this should solve your problem. If not the container in the workflow should give you an idea of how you can solve the problem that you had. 

 

Using the summary tool you can't have both MAX and MIN number at the same time because it will not work as you wish.

 

Emil_Kos_0-1600242170182.png

Please let me know if this was helpful. 

 

EDIT: After looking at @grazitti_sapna solution I realised that my solution will give you an answer showing the max date and min date but the case date will be different.

 

I was thinking that you wanted to see the max and min date but looking at the desired output I think my answer will not show what you need. 

grazitti_sapna
17 - Castor

Hi @udles5666 , try this.

grazitti_sapna_0-1600242190762.png

 

Further if you are looking to connect this with the input data, try this.

grazitti_sapna_0-1600243703535.png

 

Thanks.

 

Sapna Gupta
udles5666
8 - Asteroid

Hi @grazitti_sapna 

 

How do I add a location filter on Min Time and Max Time in the attached? Please read the scenarios below I want to cover in the logic. Attached spreadsheet and workflow package for reference. 

 

Scenario: 

 

We only have two main entrances (HMGBR5_Main_IN & HMGBR5_SNEAK_IN) & Two exit doors (HMGBR5_Main_OUT & HMGBR5_SNEAK_OUT)

 

  • BATMAN - Uses HMGBR5_SNEAK_IN to come in on 12:22:57 a.m so this will be his start time on 13-09-2020 & uses Main_Out to go out at 9:59:55 a.m which will be his finish time.

 

  • Charlie - He works night shift. (4pm - 4am next day) Comes in through HMGBR5_Main_IN at  16:16:15 p.m. which will be his start time but doesn't leave that day. The entry for 13/09/2020 3:03:57 a.m. is for the previous day. 

 

Desired Output : 

 

One row per day, per card number. 

 

Potential Case Card NumberPotential Case NameCompanyCase DateStart TimeFinish TimeEntry GateExit Gate
59960CharlieHolly Molly Guacamoley Brands (AU) Ltd13/09/202016:16:15 p.m.null/blankHMGBR5_Main_INnull/blank
59994BatmanHolly Molly Guacamoley Brands (AU) Ltd13/09/202012:22:57 a.m.9:59:55 a.m.HMGBR5_SNEAK_INHMGBR5_Main_OUT

 

 

Thanks, 

kapilthakur
7 - Meteor

@Emil_Kos @udles5666  Can you share the formula, I don't have alteryx installed but I wanted to know the formula how it's been used in such scenarios.

kapilthakur
7 - Meteor

@grazitti_sapna  Can you please share the formula as a snip. It would be great help for me.

Labels