Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Section Access - Script dies -> Help wracking brain...

Its a really simple sript rignt now. It will be integrated with another script but this bit below wont run. The script simply reports "Execution of script failed. Reload Old data. I copied a wee bit of script from for loading data inline just to be sure something wasn't really wrong. The inline script commented out below runs fine. Note that my path is good and the "load" script from qvd below is exactly what the wizzard put in the script (except REDUCTION as USERID) but I can write SQL blind so I am pretty sure this bit is fine. What's wrong? I am using the USERID as the filed that will eventually be used for dynamic data reduction.

Any ideas would be great. Also, if anyone knows where the log file would be that would help. The error message is pretty useless.

Section Access;
DIRECTORY '..\QVD';


LOAD [PASSWORD],
[ACCESS],
REDUCTION,
REDUCTION as USERID
FROM
E:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD
(qvd);


//
//LOAD * INLINE [
//ACCESS, USERID, PASSWORD, OMIT
//ADMIN, ADMIN, ADMIN,
//USER, USER1, U1, SALES
//USER, USER2, U2, WAREHOUSE
//USER, USER3, U3, EMPLOYEES
//USER, USER4, U4, SALES
//USER, USER4, U4, WAREHOUSE
//USER, USER5, U5, *
//];

1 Solution

Accepted Solutions
Miguel_Angel_Baeyens

Hello Tim,

Section Access won't load from an optimized QVD So either ot the following should work:

LOAD [PASSWORD], [ACCESS], REDUCTION, REDUCTION as USERIDFROME:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD(qvd) WHERE 1=1; // This forces an unoptimized load


LOAD UPPER([PASSWORD]) AS PASSWORD, UPPER([ACCESS]) AS ACCESS, // Just to make sure the values are being pulled correctly UPPER(REDUCTION) AS REDUCTION, // As all fields and values must be uppercase in SA UPPER(REDUCTION) as USERID // The UPPER() unoptimizes the load likewiseFROME:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD(qvd);


Hope this helps

View solution in original post

7 Replies
prieper
Master II
Master II

Do you have a SECTION APPLICATION before your script?

Alternatively you may switch off the option to create a logfile. Sometimes after a QV has crashed, the logfile is still open and prevents an update of same.

HTH
Peter

Anonymous
Not applicable
Author

I do have a SECTION APPLICATION after my SECTION ACCESS IN MY SCRIPT. If i comment out the section access, the rest of it runs fine. Its just the section access bit. Can you tell me where the error log would be for my documents - i'll try and switch off option to create a log file but i dont know what option that is? i checked under application data for Qliktech under my account and all users and nothing that i can see looks like a docoument log. I really have no idea why its dying. I have done this before without too much trouble but this one is really stumping me.

Anonymous
Not applicable
Author

I found logging I just didn't have it turned on. The log is no help at all. It says there is a general script error. Hmm.

11/27/10 02:03:20: Execution started.
11/27/10 02:03:20: QlikView Version:9.00.7320.7
11/27/10 02:03:20: 0002 SECTION ACCESS
11/27/10 02:03:20: 0004 DIRECTORY '..\QVD'
11/27/10 02:03:20: 0006 TRACE Starting section access
11/27/10 02:03:20: 0006 Starting section access

11/27/10 02:03:20: 0009 LOAD [PASSWORD] as PASSWORD,
11/27/10 02:03:20: 0010 [ACCESS] as ACCESS,
11/27/10 02:03:20: 0011 REDUCTION,
11/27/10 02:03:20: 0012 REDUCTION as USERID
11/27/10 02:03:20: 0013 FROM
11/27/10 02:03:20: 0014 E:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD
11/27/10 02:03:20: 0015 (qvd)
11/27/10 02:03:20: 4 fields found: PASSWORD, ACCESS, REDUCTION, USERID, General Script Error
11/27/10 02:03:20: Execution Failed
11/27/10 02:03:20: Execution finished.

Not applicable
Author

Not something to do with the QVD file is it? Try loading it in a test document that doesnt have section access just to make sure.

Gordon

Not applicable
Author

oh and try removing the directory statement - you are accessing the qvd with an absolute path so just to make sure QV isnt getting confused....

Miguel_Angel_Baeyens

Hello Tim,

Section Access won't load from an optimized QVD So either ot the following should work:

LOAD [PASSWORD], [ACCESS], REDUCTION, REDUCTION as USERIDFROME:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD(qvd) WHERE 1=1; // This forces an unoptimized load


LOAD UPPER([PASSWORD]) AS PASSWORD, UPPER([ACCESS]) AS ACCESS, // Just to make sure the values are being pulled correctly UPPER(REDUCTION) AS REDUCTION, // As all fields and values must be uppercase in SA UPPER(REDUCTION) as USERID // The UPPER() unoptimizes the load likewiseFROME:\Projects\Pepsi\LSDev\QVD\E_LSUSERS.QVD(qvd);


Hope this helps

Anonymous
Not applicable
Author

It works Miguel! So happy. Is that documented anywhere? I was pouring over anything I could find on section access yesterday and could not see it. Thx to others to. I did have it working without section access first and the directory statement was there because all my qvd's are in one spot. The hard coded path was one of a number of desperate attempts to make it work.