Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

beck_bakytbek
Valued Contributor III

the best way to exclude the value by joining of tables

Hi Folks,

I have a question: there are 2 Tables

Tab_A

ID, Sales

A, 1

B, 2

D, 3

and

Tab_B

ID, Sales

A, 10

B, 12

C, 13

The expected output is:

Tab

ID, Sales

D,3



what is best way to exclude the values and still only D = 3

Thanks a lot

Beck

1 Solution

Accepted Solutions

Re: the best way to exclude the value by joining of tables

If using sunny example i added Noconcatenate because table need to not concatenate

Tab_B:

LOAD ID

FROM Tab_B;

Noconcatenate

Tab_A:

LOAD ID,

    Sales

FROM Tab_A

Where not Exists(ID);


DROP Table Tab_B;

11 Replies

Re: the best way to exclude the value by joining of tables

Is this needed during loading of the data? May be this

Tab_B:

LOAD ID

FROM Tab_B;

Tab_A:

LOAD ID,

     Sales

FROM Tab_A

Where not Exists(ID);


DROP Table Tab_B;

Re: the best way to exclude the value by joining of tables

Do you need only data for D Column.

mato32188
Contributor III

Re: the best way to exclude the value by joining of tables

Hi Beck,

Tab_B:

Load ID, Sales

FROM xxx;

noconcatenate

Tab_A:

Load ID, Sales

FROM xxx

where not exists(ID);

drop table Tab_B;

BR

Martin

Re: the best way to exclude the value by joining of tables

If using sunny example i added Noconcatenate because table need to not concatenate

Tab_B:

LOAD ID

FROM Tab_B;

Noconcatenate

Tab_A:

LOAD ID,

    Sales

FROM Tab_A

Where not Exists(ID);


DROP Table Tab_B;

Re: the best way to exclude the value by joining of tables

But why is that needed its.anandrjs‌? My Tab_B only have ID and Tab_A have ID and Sales. They are not going to auto concatenate. I don't think there is a need for NoConcatenate here. Would you agree?

beck_bakytbek
Valued Contributor III

Re: the best way to exclude the value by joining of tables

Sunny Thanks a  lot for your feedback and help

beck_bakytbek
Valued Contributor III

Re: the best way to exclude the value by joining of tables

Martin Thanks a  lot for your feedback and help

beck_bakytbek
Valued Contributor III

Re: the best way to exclude the value by joining of tables

Anand Thanks a  lot for your feedback and help

Re: the best way to exclude the value by joining of tables

Because field names are same and they concatenated first, try below example and comment the Noconcatenate and rename the filed ID to some other name and see the result.

Tab_B:

LOAD * Inline

[

IDD, Sales

A, 10

B, 12

C, 13

];

//NoConcatenate

Tab_A:

LOAD * Inline

[

ID, Sales

A, 1

B, 2

D, 3

]Where not Exists(IDD,ID);

DROP Table Tab_B;

Community Browser