<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Append rows to a table in a load script in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Append-rows-to-a-table-in-a-load-script/m-p/2045784#M86017</link>
    <description>&lt;P&gt;I'm pretty new to Qlik and I'm currently struggling to add certain new rows to a table in a load script.&lt;/P&gt;
&lt;P&gt;For simplicity, let's say I have four columns in my original table:&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;name (e.g. customer name)&lt;/LI&gt;
&lt;LI&gt;value (e.g. number of items bought by the customer)&lt;/LI&gt;
&lt;LI&gt;month&lt;/LI&gt;
&lt;LI&gt;KPI (describes whether the given value is historical data or a forecast)&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;My original data may look for instance like this:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_0-1678117729840.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102085i5BAC8B22D2C9E3FE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_0-1678117729840.png" alt="saz_0-1678117729840.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Each of the forecasts (Forecast 1 // Forecast 2 // etc) starts at some point during the year. My aim is to impute the data of the earlier months with the historical data. Example:&amp;nbsp;Forecast 1 starts in February and so there is no value for Forecast 1 in January. I would like to add the historical data from January to the table, i.e. add the lines&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_1-1678117946945.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102086iFFE01B3406B98851/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_1-1678117946945.png" alt="saz_1-1678117946945.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Doing the same for the other forecast, I will end up the following table:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_2-1678118116913.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102090iE0D0948B94CEB197/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_2-1678118116913.png" alt="saz_2-1678118116913.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm a bit lost how to realize this in the load script. It will certainly require some loop(s), but I'm not really sure what is the best way to do it. I would be happy about any help! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 06 Mar 2023 16:01:23 GMT</pubDate>
    <dc:creator>saz</dc:creator>
    <dc:date>2023-03-06T16:01:23Z</dc:date>
    <item>
      <title>Append rows to a table in a load script</title>
      <link>https://community.qlik.com/t5/App-Development/Append-rows-to-a-table-in-a-load-script/m-p/2045784#M86017</link>
      <description>&lt;P&gt;I'm pretty new to Qlik and I'm currently struggling to add certain new rows to a table in a load script.&lt;/P&gt;
&lt;P&gt;For simplicity, let's say I have four columns in my original table:&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;name (e.g. customer name)&lt;/LI&gt;
&lt;LI&gt;value (e.g. number of items bought by the customer)&lt;/LI&gt;
&lt;LI&gt;month&lt;/LI&gt;
&lt;LI&gt;KPI (describes whether the given value is historical data or a forecast)&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;My original data may look for instance like this:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_0-1678117729840.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102085i5BAC8B22D2C9E3FE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_0-1678117729840.png" alt="saz_0-1678117729840.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Each of the forecasts (Forecast 1 // Forecast 2 // etc) starts at some point during the year. My aim is to impute the data of the earlier months with the historical data. Example:&amp;nbsp;Forecast 1 starts in February and so there is no value for Forecast 1 in January. I would like to add the historical data from January to the table, i.e. add the lines&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_1-1678117946945.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102086iFFE01B3406B98851/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_1-1678117946945.png" alt="saz_1-1678117946945.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Doing the same for the other forecast, I will end up the following table:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="saz_2-1678118116913.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/102090iE0D0948B94CEB197/image-size/medium?v=v2&amp;amp;px=400" role="button" title="saz_2-1678118116913.png" alt="saz_2-1678118116913.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm a bit lost how to realize this in the load script. It will certainly require some loop(s), but I'm not really sure what is the best way to do it. I would be happy about any help! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Mar 2023 16:01:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Append-rows-to-a-table-in-a-load-script/m-p/2045784#M86017</guid>
      <dc:creator>saz</dc:creator>
      <dc:date>2023-03-06T16:01:23Z</dc:date>
    </item>
  </channel>
</rss>

