Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Exclude values from excel spreadsheet when loading sql data

Hello

I am bit of a novice on Qlikview and can't seem to find a way of effectively excluding some data.

So the scenario is I have some data in an excel spreadsheet and I have master data in a sql table, I need to exclude the values that are in the spreadsheet when loading the sql data.

I have so far

Leads:

Select

BusinessName

FROM CampaignManagement..[Leads] L

where enddate is null;

Load

BusinessName,

address,

post_code,

phone,

email,

url

FROM

(biff, embedded labels, table is Adverisers$);

Where the business name in the excel file matches a business name in the Leads table, I need that row excluded.

Any help would be appreciated

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Well, depending on the requirements it will make sense or not. Check attached again and compare table object and table chart object.

I hope it clarifies your doubts.

Marc.

View solution in original post

18 Replies
Anonymous
Not applicable
Author

Hi,

Try adding this :

...

FROM

(biff, embedded labels, table is Adverisers$)

where not(exists(BusinessName));

Marc.

alexandros17
Partner - Champion III
Partner - Champion III

try with

Leads:

Select

BusinessName

FROM CampaignManagement..[Leads] L

where enddate is null;

Load

BusinessName,

address,

post_code,

phone,

email,

url

FROM

(biff, embedded labels, table is Adverisers$)

where not exists(BusinessName, BusinessName);

let me know

Not applicable
Author

Neither of the above is excluding the records

Anonymous
Not applicable
Author

My previous solution may work if you have not loaded your BusinessName before. So I assume you need another way, let's try with:

Leads:

Select

BusinessName

FROM CampaignManagement..[Leads] L

where enddate is null;

Table1:

Load

BusinessName,

address,

post_code,

phone,

email,

url

FROM

(biff, embedded labels, table is Adverisers$);

left join (table1) load *, 1 as excludename resident Leads;

Table2: noconcatenate load * resident Table1 where excludename<>1;

drop table Table1;

Marc.

Not applicable
Author

I get an error

Table not found

left join (table1) load *, 1 as excludename resident Leads

Field not found - <excludename>

Table2: noconcatenate load * resident Table1 where excludename<>1

Anonymous
Not applicable
Author

Please name your table. See where I typed "Table1" before load statement.

Marc.

Not applicable
Author

I think I have ??

Leads:

Select

BusinessName

FROM CampaignManagement..[Leads] L

where enddate is null;

Table1:

Load

BusinessName,

address,

post_code,

phone,

email,

url

FROM

(biff, embedded labels, table is Adverisers$);

left join (table1) load *, 1 as excludename resident Leads;

Table2: noconcatenate load * resident Table1 where excludename<>1;

drop table Table1;

Anonymous
Not applicable
Author

ok, then force the no-concatenation. Please add this before load statement:

Table1: Noconcatenate

Marc.

Not applicable
Author

It was

left join (table1) load *, 1 as excludename resident Leads;

should have been

left join (Table1) load *, 1 as excludename resident Leads;

ANYWAY...still not excluding the data

Sooo strange