Qlik Community

Ask a Question

App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
April 22, 2PM EST: Learn about GeoOperations in Qlik Sense SaaS READ MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
mtabernad
Partner
Partner

Got stuck with IntervalMatch

Hi community,

I have two tables. In table 1 there is a field called "NumericIPOrigen", and I want to get its "Codigo de oficina" from Table 2 when "NumericIPOrigen" is between its corresponding "NumericIP_Max" and "NumericIPMin".

 

capture25.pngcapture26.png

It has to be pretty simple but I am not able to achieve it. I would really appreciate any help.

Thank you in advance.

My script is as follows:

Amenazas:
NoConcatenate
Load
*,subfield("IP Destino",'.',1) << 24 + subfield("IP Destino",'.',2) << 16 +
subfield("IP Destino",'.',3) << 8 + subfield("IP Destino",'.',4) << 0 as NumericIp

Resident Amenazas_aux
where %Fecha<=Today();

drop Table Amenazas_aux;

OficinaPorIP:
LOAD
"Código de oficina",
NumericIp_Min,
NumericIp_Max
FROM [lib://Security_Analytics_Folder_Agbar/2.QVD/Layer2/MapeoRangosIP.QVD]
(qvd);


Left join (Amenazas)
IntervalMatch(NumericIp)
Load
NumericIp_Min,
NumericIp_Max
Resident OficinaPorIP;

drop Table OficinaPorIP;

 

 

Labels (3)
1 Solution

Accepted Solutions
petter
MVP
MVP

You should't drop the table OficinaPorIP. 

View solution in original post

3 Replies
petter
MVP
MVP

Could you please share some test data ... a small extract from each table that you made a screenshot of ?

petter
MVP
MVP

You should't drop the table OficinaPorIP. 

View solution in original post

mtabernad
Partner
Partner
Author

You're right! Thank you!