<?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 loading and join tables in for next loop in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/loading-and-join-tables-in-for-next-loop/m-p/1552433#M743984</link>
    <description>&lt;PRE&gt;YearSelection:
LOAD *
From
$(vYEARS_Path)$(vYEARS_File)
(ooxml, embedded labels, table is Years)
Where (Not IsNUll(LoadDatafromFile));

let vMin = peek('Year',0,'YearSelection');
Let vMax = peek('Year',NoOfRows('YearSelection')-1,'YearSelection');

Drop Table YearSelection; 
  
  	 For vI = $(vMin) to $(vMax)

		    Let vDataTransform = '$(vPathQVDExtract)' &amp;amp; '000_Data_' &amp;amp; '$(vI)' &amp;amp; '_Extract_MainData.qvd'; // Set the QVD Transform filepath
		    	    	    
		    // Load all the transform files and concentate IPC Data
		    DataTbl:
		    
		    Let  vData = '$(vPathQVDDashboard)' &amp;amp; '000_Dashboard_Data.qvd'; // Set the QVD Dashboard filepath
		    		    
			Load *
			From
			$(vDataTransform)
			(QVD);
	
   Next vI

			Store DataTbl into [$(vData)] (qvd);
			Drop Table DataTbl;&lt;/PRE&gt;&lt;P&gt;I am trying to load spreadsheet data for yearly spreadsheets&amp;nbsp; 2015 to 2019, 5 separate spreadsheets.&lt;/P&gt;&lt;P&gt;If all the spreadsheet fields are the same, the data is loaded and auto Concatenated and outputted into one QVD file.&lt;/P&gt;&lt;P&gt;my files must have differing fields throughout the years.&lt;/P&gt;&lt;P&gt;I end up on the load window with&lt;/P&gt;&lt;P&gt;DataTbl&lt;/P&gt;&lt;P&gt;DataTbl1&lt;/P&gt;&lt;P&gt;DataTbl1&lt;/P&gt;&lt;P&gt;DataTbl2&lt;/P&gt;&lt;P&gt;DataTbl3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;how can I join these in the above code&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;many thanks for any help or direction&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
    <dc:creator>spikenaylor1</dc:creator>
    <dc:date>2020-11-25T16:16:04Z</dc:date>
    <item>
      <title>loading and join tables in for next loop</title>
      <link>https://community.qlik.com/t5/QlikView/loading-and-join-tables-in-for-next-loop/m-p/1552433#M743984</link>
      <description>&lt;PRE&gt;YearSelection:
LOAD *
From
$(vYEARS_Path)$(vYEARS_File)
(ooxml, embedded labels, table is Years)
Where (Not IsNUll(LoadDatafromFile));

let vMin = peek('Year',0,'YearSelection');
Let vMax = peek('Year',NoOfRows('YearSelection')-1,'YearSelection');

Drop Table YearSelection; 
  
  	 For vI = $(vMin) to $(vMax)

		    Let vDataTransform = '$(vPathQVDExtract)' &amp;amp; '000_Data_' &amp;amp; '$(vI)' &amp;amp; '_Extract_MainData.qvd'; // Set the QVD Transform filepath
		    	    	    
		    // Load all the transform files and concentate IPC Data
		    DataTbl:
		    
		    Let  vData = '$(vPathQVDDashboard)' &amp;amp; '000_Dashboard_Data.qvd'; // Set the QVD Dashboard filepath
		    		    
			Load *
			From
			$(vDataTransform)
			(QVD);
	
   Next vI

			Store DataTbl into [$(vData)] (qvd);
			Drop Table DataTbl;&lt;/PRE&gt;&lt;P&gt;I am trying to load spreadsheet data for yearly spreadsheets&amp;nbsp; 2015 to 2019, 5 separate spreadsheets.&lt;/P&gt;&lt;P&gt;If all the spreadsheet fields are the same, the data is loaded and auto Concatenated and outputted into one QVD file.&lt;/P&gt;&lt;P&gt;my files must have differing fields throughout the years.&lt;/P&gt;&lt;P&gt;I end up on the load window with&lt;/P&gt;&lt;P&gt;DataTbl&lt;/P&gt;&lt;P&gt;DataTbl1&lt;/P&gt;&lt;P&gt;DataTbl1&lt;/P&gt;&lt;P&gt;DataTbl2&lt;/P&gt;&lt;P&gt;DataTbl3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;how can I join these in the above code&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;many thanks for any help or direction&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/loading-and-join-tables-in-for-next-loop/m-p/1552433#M743984</guid>
      <dc:creator>spikenaylor1</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: loading and join tables in for next loop</title>
      <link>https://community.qlik.com/t5/QlikView/loading-and-join-tables-in-for-next-loop/m-p/1552446#M743985</link>
      <description>&lt;P&gt;Try to force a concatenate into your load. This should eliminate your problems.&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;YearSelection:
LOAD *
From
$(vYEARS_Path)$(vYEARS_File)
(ooxml, embedded labels, table is Years)
Where (Not IsNUll(LoadDatafromFile));

let vMin = peek('Year',0,'YearSelection');
Let vMax = peek('Year',NoOfRows('YearSelection')-1,'YearSelection');
&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;DataTbl:&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;LOAD * inline [&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;DummyField];&lt;/STRONG&gt;&lt;BR /&gt;
Drop Table YearSelection; 
  
  	 For vI = $(vMin) to $(vMax)
		    Let vDataTransform = '$(vPathQVDExtract)' &amp;amp; '000_Data_' &amp;amp; '$(vI)' &amp;amp; '_Extract_MainData.qvd'; // Set the QVD Transform filepath
		    // Load all the transform files and concentate IPC Data
		    Let  vData = '$(vPathQVDDashboard)' &amp;amp; '000_Dashboard_Data.qvd'; // Set the QVD Dashboard filepath		    		    
			&lt;STRONG&gt;Concatenate(DataTbl)&lt;/STRONG&gt;&lt;BR /&gt;                        Load *
			From
			$(vDataTransform)
			(QVD);
   Next vI
                   &lt;STRONG&gt;     Drop field DummyField;&lt;/STRONG&gt;
			Store DataTbl into [$(vData)] (qvd);
			Drop Table DataTbl;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Mar 2019 14:37:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/loading-and-join-tables-in-for-next-loop/m-p/1552446#M743985</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2019-03-05T14:37:51Z</dc:date>
    </item>
  </channel>
</rss>

