Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

olguita2014
Contributor

Problems with RAM memory

Hi,

Please help me...

The script that I run, shows me an error: Unknown load. From what I have observed is due to RAM problems.

Please can you help me how I can optimize the following code:

NoConcatenate

fc_Core_Cuenta_tmp3:

Load

*,

If(

          Match(Right(Left(Cuentas_Nivel6,8),2),'01','02','03','04','05','06','07','08','09','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31','32','33','34','35','36','37','38','39','40','41','42','43','44','45','46','47','48','49','50','51','52','53','54','55','56','57','58','59','60',

          '61', '62', '63', '64', '65', '66', '67', '68', '69', '70', '71', '72', '73', '74', '75', '76', '77', '78', '79', '80', '81', '82', '83', '84', '85', '86', '87', '88', '89', '90'),Left(Cuentas_Nivel6,8)

      )

      as Cuentas_Nivel5

Resident fc_Core_Cuenta_tmp2;

Join

Load

Cuenta_Long8 as Cuentas_Nivel5,

Valor_Cuenta as Valor_Cuenta5

Resident fc_Core_Cuenta_tmp;

Drop Table fc_Core_Cuenta_tmp2;

Upload the RAM when I insert the "JOIN"

6 Replies
cristinapo
New Contributor III

Re: Problems with RAM memory

Are you sure you want a full join? JOIN statement is a full join.

Maybe an inner join would save the situation if it actually is a RAM issue. Or at least a left or right join (depending on what you want to keep).

Also, I think you can move Drop Table fc_Core_Cuenta_tmp2; just before the join statement, as you will save some space with this table that you don't invoke anymore.

olguita2014
Contributor

Re: Problems with RAM memory

Hi,

Yes, I need full join.... I can not remove fc_Core_Cuenta_tmp2 because I use the data in that table

cristinapo
New Contributor III

Re: Problems with RAM memory

What I meant earlier with fc_Core_Cuenta_tmp2 is that you already drop it in the last line of code that you pasted. So instead of dropping it at the last moment, you can drop it just before the JOIN statement (see below adjusted script) because the JOIN code doesn't refer to fc_Core_Cuenta_tmp2 anymore, but to

fc_Core_Cuenta_tmp as I see.

NoConcatenate

fc_Core_Cuenta_tmp3:

Load

*,

If(

          Match(Right(Left(Cuentas_Nivel6,8),2),'01','02','03','04','05','06','07','08','09','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31','32','33','34','35','36','37','38','39','40','41','42','43','44','45','46','47','48','49','50','51','52','53','54','55','56','57','58','59','60',

          '61', '62', '63', '64', '65', '66', '67', '68', '69', '70', '71', '72', '73', '74', '75', '76', '77', '78', '79', '80', '81', '82', '83', '84', '85', '86', '87', '88', '89', '90'),Left(Cuentas_Nivel6,8)

      )

      as Cuentas_Nivel5

Resident fc_Core_Cuenta_tmp2;

Drop Table fc_Core_Cuenta_tmp2;  //moved here

Join

Load

Cuenta_Long8 as Cuentas_Nivel5,

Valor_Cuenta as Valor_Cuenta5

Resident fc_Core_Cuenta_tmp;

Drop Table fc_Core_Cuenta_tmp2;

So, by doing this, you may end up with some saved RAM.

olguita2014
Contributor

Re: Problems with RAM memory

I try this, but I have the same problem:

Untitled.png

silvacarlos
Contributor II

Re: Problems with RAM memory

Maybe a Load Distinct on the Join?

CS

cristinapo
New Contributor III

Re: Problems with RAM memory

Also, can you force it by stating JOIN (fc_Core_Cuenta_tmp3) instead of the simple JOIN?