title: Macro to call datasets and concatenate it
body: <p>I know to how to call different tables from my folder. This is done with the <code>function : %let x1 = libname.foldername</code>. My problem is how to do it on 1000 tables with a simple macro</p>
  
  <p>SAS</p>
  
  <pre><code>%Let Table1=project.table_201710; 
  %Let Table2=project.table_201711;
  %Let Table3=project.table_201712;
  %Let Table4=project.table_201801;
  %Let Table5=project.table_201802; 
  %Let Table6=project.table_201803;
  %Let Table7=project.table_201804;
  %Let Table8=project.table_201805;
  %Let Table9=project.table_201806;
  %Let Table10=project.table_201807;
  %Let Table11=project.table_201808;
  %Let Table12=project.table_201809;
  
  %Macro ConcatTable;
  Data project.TABLE_FINALE; 
  Set
  %Do i=1 %To 12;
  &amp;&amp;Table&amp;i. 
  %End;
  ;
  Run;
  %Mend ConcatTable;
  %ConcatTable
  </code></pre>