Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
MindaugasBacius
Partner - Specialist III
Partner - Specialist III

Unique intervals

Hello,

I have data like this (see the attachment):

Screenshot_1.jpg

I need to have unique intervals without overlapping intervals.

The outcome should be like this:

Screenshot_1.jpg

There are few ways to get the correct result. But unfortunately I cannot come up with the correct logic here.

Thank you in advance!

1 Solution

Accepted Solutions
maxgro
MVP
MVP

my attempt in the attachment

1.png

View solution in original post

6 Replies
Gysbert_Wassenaar

I'm afraid I don't understand the result you want. The first two rows in your outcome screenshot show two intervals that overlap.


talk is cheap, supply exceeds demand
MindaugasBacius
Partner - Specialist III
Partner - Specialist III
Author

Screenshot_1.jpg

E and F columns shows rows that should be deleted or kept in the result.

There are two ways to make it correct but it depends on how you manage the issue. Both outputs suit me.

Gysbert_Wassenaar

It's still not clear to me. But have a look at page 17 and 18 of the pdf file attached to this document: IntervalMatch and Slowly Changing Dimensions


talk is cheap, supply exceeds demand
raajaswin
Creator III
Creator III

I think this is what you want..  It gives column F value

maxgro
MVP
MVP

my attempt in the attachment

1.png

MindaugasBacius
Partner - Specialist III
Partner - Specialist III
Author

Could you please take a look at this issue:

Overlapping intervals