14 Replies Latest reply: Aug 4, 2014 1:07 PM by Srikanth P RSS

    Joining the Intervalmatch output with main query

    Sonali Sardesai

      Hello All,


      While optimizing the SQL query in QlikView, i have come across a situation where i have to use intervalmatch for comparing dates from 2 tables which are not linked using any field and need to inner/left join the intervalmatch output with the main query.


      For eg

      Table A has 4 columns

      Emp IDStart DateEnd DateLocation ID


      Table B has 3 Columns basically a table with all the transaction dates from 1990 till year 2019 capturing all the transactions posted to GL

      IDTransaction DateBusiness Flag


      Both the above tables are not linked using any ID's, using interval match i need to find out the location id's of employees where the Transaction dates from table B  are between the start date and end date of table A.

      Transaction Date >= Start date and Transaction Date <= End Date.


      Once i get this output i need to left join it with the main query which has other employee details. How to left join this output in the main query Can anybody help?