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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Load filter

Hi,

I wish to load into QVD from Oracle View with selected value, I tried below but failed, please help. Thank you.

[TableName]:

LOAD *

SQL SELECT *

FROM VIEW_NAME ;

WHERE date >='2014-12-31'

STORE TableName into new.qvd;

8 Replies
sunny_talwar

Try this:

[TableName]:

LOAD *

SQL SELECT *

FROM VIEW_NAME

WHERE date >='2014-12-31';

STORE TableName into new.qvd;


You misplaced your semi-colon after the FROM statement instead of using it after the WHERE statement.

Not applicable
Author

can you be more specific with what failed?  did you not get the expected results or was an error displayed when the load script was run?

ramasaisaksoft

Hi Andros,

You did a small mistake i.e you can't close/Stop the query (;) before where condition it needs to be close after where condition.

try the below one

[TableName]:

LOAD *

SQL SELECT *

FROM VIEW_NAME

WHERE date >='2014-12-31';

STORE TableName into newTable.qvd(QVD);

Not applicable
Author

I was making the assumption what was being shown was not the actual code, but if it is, then I agree there are the syntax errors described above

Not applicable
Author

Hi Andros, try this:

Try this:

[TableName]:

LOAD *

SQL SELECT *

FROM VIEW_NAME

WHERE date >='2014-12-31';

STORE TableName into new.qvd;

You were putting the ' ; ' in the incorrect place.

I hope that it help you!

Regards, Agustin

Not applicable
Author

Hi Agustin,

I was trying to store the data into QVD from a Oracle View. Anyway I will jut do a filter when loading into Table then. Thank you.

Another question :

In the script below, the OMSPO# consist of PO no like :

000123

000123-1

000123-2

000234

000234-1

000234-2

023123

0123123

But I only want to lad those PO no. without '-' as these are sub-PO.

meaning I only wants to load 000123, 00234, 023123, 0123123.

Appreciate your help.

[Shipment]:
load
fileNumber, orderNumber, primaryReference,
primaryReference as OMSPO#,
serviceLevel as TransportMode,
departmentCode as Department,
creationEmployeeName as LoginUser,
statusCode as POStatus
FROM [Shipments.qvd] (qvd);

sunny_talwar

Try this:

[Shipment]:

LOAD fileNumber, orderNumber, primaryReference,

primaryReference as OMSPO#,

serviceLevel as TransportMode,

departmentCode as Department,

creationEmployeeName as LoginUser,

statusCode as POStatus

FROM [Shipments.qvd] (qvd)

Where Len(Trim(KeepChar(primaryReference, '-'))) = 0;

sunny_talwar

Sample:

Table:

LOAD primaryReference as [OMSPO#]

Where Len(Trim(KeepChar(primaryReference, '-'))) = 0;

LOAD * Inline [

primaryReference

000123

000123-1

000123-2

000234

000234-1

000234-2

023123

0123123

];

Capture.PNG