Start Free Trial

Alteryx Designer Desktop Discussions

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

Filter excel sheet based on total hours in a Week

Asad1
6 - Meteoroid

I have a excel sheet where I have 3 cols. The first col is the name, second is hours and third is date.

 

Col1      Col2       Col3

A            2hr        1feb

B            4hr        1feb

C            3hr        1feb

D            2hr        1feb

A            3hr        2feb

B            2hr        2feb

D            3hr        2feb

A            2hr        2feb

C            3hr        2feb

 

Now I want to filter this excel sheet based on the date and hour. So, I want to check that if a person exceeds 10hrs in a week (e.g. from 1-7feb, 8-14feb….)

6 REPLIES 6
aatalai
15 - Aurora

@Asad1 try this

 

step 1 create a week number idnetifier

 

assuming column 3 is already in date format

 

use the following expression

 

ceil( DateTimeDay([col C]/7,1)

 

 

step 2

 

 

assuming col B is in number format 

 

 

group by newly created filed and sum col B, using the summarise tool

 

step 3

 

 

use the filter tool setting the sum threshold to 10 and the sign (great than/less than etc) as desired.

 

Hope this helps

 

 

 

Asad1
6 - Meteoroid

Thanks @aatalai ,

 

Could you possibly provide me with a sample workflow for your explanation. Because I do not quite understand which tools to use for this.

 

Thank you.

aatalai
15 - Aurora

@Asad1 this should help, used the example you provide, first couple tools might not be needed as I needed them given the format of the example let me know how you get on

Manoj_k
9 - Comet

hi @Asad1 i have attached the workflow, it is almost same to the output you wanted

Asad1
6 - Meteoroid

Hello @aatalai 

 

I tried your workflow but the formula tool for the date format is showing an error: "Error: Formula (5): Parse Error at char(0): Wrong number of parameters for the function "CEIL". (Expression #2)"

 

Can you you please help with this, thanks.

aatalai
15 - Aurora

@Asad1 have you set your number to double

Labels
Top Solution Authors