Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
LauraMorris
Contributor III
Contributor III

Using where clause in load statement

Having searched the forum and tried many of the suggestions I still cannot get a simple where clause to work in my load script. I've been going round in circles for 9 hours now.  Looking at previous answers I need to use a resident load and do it there but I'm still getting either 0 results if I use ' or everything if I dont use any quotes. I've taken all other tables out until I get this bit working to try and simplify things. My script at the minute is:

 

[service2]:
LOAD
"$_serviceid",
....
"$_clientid",
FROM [lib://QVDs/PHS QVDs DEV\service.qvd]

(qvd);


[service]:

NOCONCATENATE  LOAD

*

RESIDENT service2

WHERE $_clientid = 37;

DROP TABLE service2;

Labels (1)
1 Reply
Arthur_Fong
Partner - Specialist III
Partner - Specialist III

Try to alias your column name:
[service2]:
LOAD
"$_serviceid" as [ServiceID],
....
"$_clientid" as [ClientID],
FROM [lib://QVDs/PHS QVDs DEV\service.qvd]

(qvd);


[service]:

NOCONCATENATE LOAD

*

RESIDENT service2

WHERE [ClientID] = 37;

DROP TABLE service2;