Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

d_prashanthredd
Contributor III

Extract Dates from Date Range

Hi,

I'm working on data which extracted from Google Calendar where the users update their PTOs, Work From Home, etc. I'm able to extract the info but I need it in a different format.

Extracted Info:

In above example, 1st row date range is from 3rd May to 11th May (total 6 Days). But I want to represent the same in 6 rows as 5th May, 6th May till 10th May as I need to exclude weekends or if any public holidays.

Ex: Output should be like below (For 1st Row and so on)..

Kiran Gade PTO           Kiran           PTO           2017-03-05
Kiran Gade PTO           Kiran           PTO           2017-03-06
Kiran Gade PTO           Kiran           PTO           2017-03-07
Kiran Gade PTO           Kiran           PTO           2017-03-08
Kiran Gade PTO           Kiran           PTO           2017-03-09
Kiran Gade PTO           Kiran           PTO           2017-03-10

In some cases, start and end date values are showing as

Start -  2016-08-19T00:00:00+05:30

End - 2016-08-19T01:00:00+05:30

Thanks,

Prashanth Reddy D.

1 Solution

Accepted Solutions
aarkay29
Valued Contributor

Re: Extract Dates from Date Range

4 Replies
aarkay29
Valued Contributor

Re: Extract Dates from Date Range

effinty2112
Honored Contributor

Re: Extract Dates from Date Range

Hi Prashanth,

Look up the IntervalMatch function with extended syntax. You can create a calendar that runs from your earliest date to the last and includes all in between. Then a line in the script something like this might do the trick.

IntervalMatch([Calendar Date],Resource, PTOorWFH) Load start,end, Resource, PTOorWFH Resident YourTableName

cheers

Andrew

d_prashanthredd
Contributor III

Re: Extract Dates from Date Range

Thanks Kay.. I used while to get the required data set.

d_prashanthredd
Contributor III

Re: Extract Dates from Date Range

Thanks Andrew.. I did it with While.

Community Browser