1 Reply Latest reply: Mar 22, 2017 5:26 PM by Vladimir Komarov RSS

    insert in multiple table in a loop

    Mohammad Adnan Ansari

      I have to write the below logic:

       

      For i <= TotalNoOfRecordinTable Loop

       

      if i.recordType = 'T' then

      insert into TTable values ('.............);

       

      elseif i.recordType='C' then

      insert into CTable values (.......);

       

      End if;

       

       

      How I write this logic in Qlik View or QlikSense?

        • Re: insert in multiple table in a loop
          Vladimir Komarov

          Could you please elaborate on your requirements a little bit?

           

          Do you need to assign specific values to multiple fields in each table?

          Or it's just one specific field in each table needs to be updated based on the i.recordType?

           

          In the second case you should be able to do it with setting variables in the for... next loop and assigning these variables to specific fields...

           

          Regards,

          Vlad