Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm experiencing strange script errors when coding in Section Access.
Firstly, if I use this in Section Application..
Users_Table:
REPLACE
LOAD
ACCESS,
NTNAME,
CCG AS LOGGEDIN_CCG
FROM
[Users list.qvd] (qvd);
It loads ok in full and partial reload.
If I cut it from section application and paste into section access it fails in both full and partial reload with the log file stating 'general script error'.
If I modify the script in section access to a preceding load:
Users_Table:
REPLACE
LOAD
ACCESS,
NTNAME,
CCG AS LOGGEDINCCG;
LOAD
ACCESS,
NTNAME,
CCG
FROM
[Users list.qvd] (qvd);
It will run in both full and partial reload.
If the source was from a worksheet, the script will run in both full and partial reload without the need for a preceding load but still aliasing the CCG field.
Comments welcome please. We're using Version10 SR6 64bit edition and being executed in developers desktop.
Hi,
try adding where 1 = 1 this will cause the qvd not being bulk loaded.
section access;
LOAD
ACCESS,
NTNAME,
CCG AS LOGGEDIN_CCG
FROM
[Users list.qvd] (qvd) where 1 =1;
section application;
This is a known issue for section access with qvd. Therefore your preceding load may work because it finally loads each record...
Best
Stefan
I think the reason is the replace-statement which conflicts with the logic from section access. Further you won't be have a real advantage from a preceeding load or other optimizations if you only loads a few users from a qvd (probably < 100k).
- Marcus
Hi Marcus,
The only reason the preceding load is there is to get the command to actually execute. Without the preceding load I get a 'general script error' in the log and the script fails.
I know I've managed to overcome the problem by using preceding load, but I don't understand the strange behaviour of having to use a preceding load.
Hi,
try adding where 1 = 1 this will cause the qvd not being bulk loaded.
section access;
LOAD
ACCESS,
NTNAME,
CCG AS LOGGEDIN_CCG
FROM
[Users list.qvd] (qvd) where 1 =1;
section application;
This is a known issue for section access with qvd. Therefore your preceding load may work because it finally loads each record...
Best
Stefan
Yeah, not fully understanding why adding WHERE 1 = 1 works, but it does.
As it's a known issue (bug) then fair enough.
Strange, but part of my original testing involved a search filter of
SELECT
ACCESS,
NTNAME,
CCG AS LOGGEDIN_CCG
WHERE
DASHBOARDS LIKE '*PRESCRIBING*'
and that also failed with 'general script error'.
But amending it to
WHERE
1 = 1
AND
DASHBOARDS LIKE '*PRESCRIBING*'
and this executes successfully.