Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to exclude values from table in load statement

Hello,

I am trying to load a table to QV but exclude rows where column A = 'X'.  What is the syntax for this?  I thought I could just add a WHERE statement but can't find the correct way to do this.  Here is my code currently:

 

SQL

SELECT *
FROM CIA.dbo."CU_Prem_Mbrship";

Let me know if that is not clear.  Thanks.

Craig

1 Solution

Accepted Solutions
jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

where A <> 'X'

Regards,

Jagan.

View solution in original post

8 Replies
MayilVahanan

HI

Table1:

Load *;

SQL

SELECT *
FROM CIA.dbo."CU_Prem_Mbrship" where A = 'X';

Then store inqvd;


Store Table1 into TableName.qvd(qvd);

Then use qvd.. Because inorder to avoid the connect the database for every time. For qvd , its easy to load when compare to sql connection(data retrieval).

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
jagan
Luminary Alumni
Luminary Alumni

Hi,

You can straight away use where condition in SQL query.  Please check below query

TableName:

SQL SELECT *
FROM CIA.dbo."CU_Prem_Mbrship"

where A = 'X';

Hope this helps you.

Regards,

Jagan.



Not applicable
Author

How do you do A NOT = 'X'?

Thanks

haymarketpaul
Creator III
Creator III

Where A <> 'X'

jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

where A <> 'X'

Regards,

Jagan.

MayilVahanan

Hi

Try like this

SQL

SELECT *
FROM CIA.dbo."CU_Prem_Mbrship" where A <> 'X';

Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Hi Mayil,

I have the where statement figured out but still trying to understand why you advocate saving my tables as qvd.  Will this improve processing time within the application (pivot table calculations when filtering)?  Will this save space?

Thanks

MayilVahanan

HI

By using connection string, every time data fetch from database(sql). so its take time to load the data when compare to qvd. So only i mentioned like that..

Hope attached file helps you to understand about qvd.

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.