Qlik Community

Qlik Sense Cloud Discussions

Highlighted
Partner
Partner

MS SQL tables in load script - joins and operators

Hi,

I am quite new with Qlik Sense and this is the first time I wrote to community. I have connection to MS SQL server and I would like to know, how I can use OR between fields that are in different tables when i have joins or keeps ?

My data is similar to this (more tables and relations though):

LOAD product1,
product2,
product3

[product_hierarchy]:

SELECT  "product1",
"product2",
"product3",
FROM Sales.aa."product_hierarchy"

INNER JOIN ([product_hierarchy])

LOAD segment1,
segment2,
segment3

[segment_hierarchy]:

SELECT  "segment1",
"segment2",
"segment3",
FROM Sales.aa."segment_hierarchy"

I would like to do the following:  where product1 not in ('unknown') OR where segment3 not in ('business'). I know I can do both separately after the FROMs, but how I  can use OR? Are the only choices to write everything in SQL and forget the data load script or to do all the relations in data manager? Is it possible to have both data load script and SQL and make relations between two (or multiple tables) and then have OR between between fields in different tables?

BR and thank you! 

AJ

1 Reply
Partner
Partner

Re: MS SQL tables in load script - joins and operators

Addition: I guess that doing everything in data manager won`t solve the problem?