Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
ashwath26_95
Contributor II
Contributor II

How to load QVS file in Qliksense

I have the following script in a QVS File

[store]:
LOAD
[Row ID],
[Order ID],
[Order Date],
[Ship Date],
[Ship Mode],
[Customer ID],
[Customer Name],
Segment,
Country,
City,
State,
[Postal Code],
Region,
[Product ID],
Category,
[Sub-Category],
[Product Name],
Sales,
Quantity,
Discount,
Profit
FROM [C:/Users/HP/Desktop/Sample - Superstore.xls]
(biff, embedded labels, table is Orders$);

 

I am trying to load this script using following command  

$(Must_Include=[lib://store/finalsql.qvs]);

 

But i am getting following error 

The following error occurred:
This statement only works with lib:// paths in this script mode

 

Labels (1)
4 Replies
Vegar
MVP
MVP

Your qvs is referencing to [C:/Users/HP/Desktop/Sample - Superstore.xls], but you can not do that in Qlik Sense, you will need to reference to your file via a LIB.

$(Must_Include) and $(Include) is equivalent to paste your qvs content into your script and therefore need to follow the same rules as the rest of the Qlik Sense script.

(It is is possible to reference to files on the drive like [C:/Users/HP/Desktop/Sample - Superstore.xls], but then you need to configure your Qlik Sense Enterprise Server into Legacy mode.)
ashwath26_95
Contributor II
Contributor II
Author

Thank you for the reply. I have created a connection, which becomes the lib path.. now without good to legacy more how do i load
ashwath26_95
Contributor II
Contributor II
Author

Thank you for the reply. I have created a connection, which becomes the lib path. Now without good to legacy more how do i load
Vegar
MVP
MVP

Your include is probably ok.
$(Must_Include=[lib://store/finalsql.qvs]);

It is the content of finalsql.qvs you need to edit. Changing the drive path into a valid LIB-path. When that is done your script will probably run as desired.