Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I need to set a variable with the total number of rows from a table.
To achieve this, I've done the following:
TOTAL_ERRORES:
LOAD Count(ID_REGISTRY) as total_errores RESIDENT DQ_REGISTRY;
LET total_errores = if(isnull(Peek(total_errores,0,TOTAL_ERRORES)),0,Peek(total_errores,0,TOTAL_ERRORES));
Could you please tell me if this is the better/simpler way to do it?
Thank you.
Try using the NoOfRows() function:
Let total_errors = NoOfRows('TOTAL_ERRORES')
Try using the NoOfRows() function:
Let total_errors = NoOfRows('TOTAL_ERRORES')
Thak you Gary,
anyway, the correct expression was
Let total_errors = NoOfRows('DQ_REGISTRY')
But it works. Thanks.