Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
we are using lastvalue() fuction in the script almost 30 times due to which the script execution taking huge memory and leads to Inconstance memory Type A error.
Ex:
Table_A:
load A,B,c ... from xyz.qvd;
Tabla B:
load lastvalue(A) as lastname_a,
lastvalue(B) as lastname_b,
resident Table_A ;
like above lastvalue() fuction used almost 30 times in the script. I think replacing it with some similar fuction which will serve the purpose is going to fix this issue..
please suggest the suitable function to replace the lastvalue() fuction. Thanks Much in advance.
Perhaps you can use Peek() to get the results from the previous load:
Table_A:
load A,B,c ... from xyz.qvd;
Let vA = Peek('A', -1); //-1 gets last value loaded
Let vB = Peek('B', -1);
If you need them in a table, then add:
Table_B:
LOAD '$(vA)' as lastname_a,
'$(vB)' as lastname_b
AUTOGENERATE 1;
Perhaps you can use Peek() to get the results from the previous load:
Table_A:
load A,B,c ... from xyz.qvd;
Let vA = Peek('A', -1); //-1 gets last value loaded
Let vB = Peek('B', -1);
If you need them in a table, then add:
Table_B:
LOAD '$(vA)' as lastname_a,
'$(vB)' as lastname_b
AUTOGENERATE 1;