Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
cristian_av
Creator III
Creator III

Call subroutine with table name as argument

Hi

I'm getting the following error: "Script line error" when I call a subroutine. I'm just trying to learn how to use procedures..

I've tryed with many ways to call the subroutine, but i always get the same error.

Can anybody please help me?

Thanks!

-------------------------------------------------

[Hoja1]:

LOAD CAS_TRANSIT_ID, CARD_NUMBER, ESTADO, RUT, TERMINAL, KIOSCO, SERVICIO, CTTO, RUT_EMPRESA, CENTRO_COSTO, RAZON_SOCIAL, GERENCIA, TRANSIT_DATE, INSERT_DATE FROM [..\..\ConsumosExcel\ConsumoExcel2014-06.xlsm] (ooxml, embedded labels, table is Hoja1);

SET vVar ='Hola';

CALL testTransformarDatos(Hoja1);

CALL testTransformarDatos('Hoja1');

CALL testTransformarDatos($(vVar));

SUB testTransformarDatos(vTablaOrigen)

     DROP TABLE $(vTablaOrigen);

END SUB

1 Solution

Accepted Solutions
maxgro
MVP
MVP

[Hojal]:

LOAD * inline [

field

a

1

];

SUB testTransformarDatos(vTablaOrigen)

     DROP TABLE $(vTablaOrigen);

END SUB

SET vVar ='Hojal';

//CALL testTransformarDatos(Hoja1);

//CALL testTransformarDatos('Hoja1');

CALL testTransformarDatos('$(vVar)');

View solution in original post

2 Replies
maxgro
MVP
MVP

[Hojal]:

LOAD * inline [

field

a

1

];

SUB testTransformarDatos(vTablaOrigen)

     DROP TABLE $(vTablaOrigen);

END SUB

SET vVar ='Hojal';

//CALL testTransformarDatos(Hoja1);

//CALL testTransformarDatos('Hoja1');

CALL testTransformarDatos('$(vVar)');

cristian_av
Creator III
Creator III
Author

Thank you!

I didn't know that i have to put the procedure on the first tab..