Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to associate 2 tables with a between condition

I have 1 table of prices with start date and end date, like this:

31.12.201231.12.4100

Price_line_id

List NameItem_idStart_dateEnd_datePrice
1List1101.01.201210
6List1101.01.201315
2List1201.01.201231.12.410012
3List2101.01.201231.12.201211
5List2101.01.201331.12.410016
4List2301.01.201231.12.410020

1 other table of orders lines with a date, the price list name and the item.

Order_lineOrder_datePrice ListItem_idQty
130.12.2012List1110
230.12.2012List1210
330.12.2012List2110
403.01.2013List1110
503.01.2013List2110
603.01.2013List2310

And i will have this result:

10
Order_lineOrder_datePrice ListItem_idQtyPrice_line_idPriceTotal
130.12.2012List11101100
230.12.2012List1210212120
330.12.2012List2110311110
403.01.2013List1110615150
503.01.2013List2110516160
603.01.2013List2310420200

Easy to explain

But i don't have find a solution for linking the price line with the order line with the Order.order_date between the Prices.Start_date and Prices.End_date. 

1 Solution

Accepted Solutions
sushil353
Master II
Master II

Use interval Match function for the solution

HTh

Sushil

View solution in original post

1 Reply
sushil353
Master II
Master II

Use interval Match function for the solution

HTh

Sushil