title: Power query Excel Loop Date
body: <p>i would like to loop this query directly in excel powerquery. I would like to loop the date found in the link: from the date in the link to today's date. the data must all be inserted into a query. how can i solve? thank you.</p>
  <pre><code>let
      Origine = Web.Page(Web.Contents(&quot;https://www.forebet.com/scripts/getrs.php?ln=it&amp;tp=bts&amp;in=2019-06-01&amp;ord=0&quot;)),
      Data0 = Origine{0}[Data],
      Children = Data0{0}[Children],
      Children1 = Children{1}[Children],
      #&quot;Rimosse colonne&quot; = Table.RemoveColumns(Children1,{&quot;Kind&quot;, &quot;Name&quot;, &quot;Children&quot;}),
      #&quot;Analizzato JSON&quot; = Table.TransformColumns(#&quot;Rimosse colonne&quot;,{},Json.Document),
      Text = #&quot;Analizzato JSON&quot;{0}[Text],
      #&quot;Conversione in tabella&quot; = Table.FromList(Text, Splitter.SplitByNothing(), null, null, ExtraValues.Error),
      #&quot;Tabella Column1 espansa&quot; = Table.ExpandRecordColumn(#&quot;Conversione in tabella&quot;, &quot;Column1&quot;, {&quot;id&quot;, &quot;host_id&quot;, &quot;guest_id&quot;, &quot;league_id&quot;, &quot;Round&quot;, &quot;Host_SC&quot;, &quot;Guest_SC&quot;, &quot;DATE&quot;, &quot;DATE_BAH&quot;, &quot;Host_SC_HT&quot;, &quot;Guest_SC_HT&quot;, &quot;comment&quot;, &quot;match_preview&quot;, &quot;host_stadium&quot;, &quot;match_stadium&quot;, &quot;HOST_NAME&quot;, &quot;GUEST_NAME&quot;, &quot;penalty_score&quot;, &quot;extra_time_score&quot;, &quot;goalsavg&quot;, &quot;host_sc_pr&quot;, &quot;guest_sc_pr&quot;, &quot;weather_low&quot;, &quot;weather_high&quot;, &quot;weather_code&quot;, &quot;short_tag&quot;, &quot;Pred_gg&quot;, &quot;Pred_no_gg&quot;, &quot;odds_gg&quot;, &quot;odds_gg_frac&quot;, &quot;odds_gg_y&quot;, &quot;odds_gg_n&quot;, &quot;odds_gg_y_frac&quot;, &quot;odds_gg_n_frac&quot;}, {&quot;Column1.id&quot;, &quot;Column1.host_id&quot;, &quot;Column1.guest_id&quot;, &quot;Column1.league_id&quot;, &quot;Column1.Round&quot;, &quot;Column1.Host_SC&quot;, &quot;Column1.Guest_SC&quot;, &quot;Column1.DATE&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Column1.Host_SC_HT&quot;, &quot;Column1.Guest_SC_HT&quot;, &quot;Column1.comment&quot;, &quot;Column1.match_preview&quot;, &quot;Column1.host_stadium&quot;, &quot;Column1.match_stadium&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Riordinate colonne&quot; = Table.ReorderColumns(#&quot;Tabella Column1 espansa&quot;,{&quot;Column1.Round&quot;, &quot;Column1.id&quot;, &quot;Column1.host_id&quot;, &quot;Column1.guest_id&quot;, &quot;Column1.league_id&quot;, &quot;Column1.Host_SC&quot;, &quot;Column1.Guest_SC&quot;, &quot;Column1.DATE&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Column1.Host_SC_HT&quot;, &quot;Column1.Guest_SC_HT&quot;, &quot;Column1.comment&quot;, &quot;Column1.match_preview&quot;, &quot;Column1.host_stadium&quot;, &quot;Column1.match_stadium&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne1&quot; = Table.RemoveColumns(#&quot;Riordinate colonne&quot;,{&quot;Column1.id&quot;, &quot;Column1.host_id&quot;, &quot;Column1.guest_id&quot;, &quot;Column1.league_id&quot;}),
      #&quot;Merge di colonne&quot; = Table.CombineColumns(#&quot;Rimosse colonne1&quot;,{&quot;Column1.Host_SC&quot;, &quot;Column1.Guest_SC&quot;},Combiner.CombineTextByDelimiter(&quot;:&quot;, QuoteStyle.None),&quot;Sottoposto a merge&quot;),
      #&quot;Merge di colonne1&quot; = Table.CombineColumns(#&quot;Merge di colonne&quot;,{&quot;Column1.Host_SC_HT&quot;, &quot;Column1.Guest_SC_HT&quot;},Combiner.CombineTextByDelimiter(&quot;:&quot;, QuoteStyle.None),&quot;Sottoposto a merge.1&quot;),
      #&quot;Riordinate colonne1&quot; = Table.ReorderColumns(#&quot;Merge di colonne1&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.DATE&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Column1.match_preview&quot;, &quot;Column1.host_stadium&quot;, &quot;Column1.match_stadium&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne2&quot; = Table.RemoveColumns(#&quot;Riordinate colonne1&quot;,{&quot;Column1.DATE&quot;}),
      #&quot;Riordinate colonne2&quot; = Table.ReorderColumns(#&quot;Rimosse colonne2&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.match_preview&quot;, &quot;Column1.host_stadium&quot;, &quot;Column1.match_stadium&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne3&quot; = Table.RemoveColumns(#&quot;Riordinate colonne2&quot;,{&quot;Column1.match_preview&quot;, &quot;Column1.host_stadium&quot;, &quot;Column1.match_stadium&quot;}),
      #&quot;Riordinate colonne3&quot; = Table.ReorderColumns(#&quot;Rimosse colonne3&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne4&quot; = Table.RemoveColumns(#&quot;Riordinate colonne3&quot;,{&quot;Column1.penalty_score&quot;, &quot;Column1.extra_time_score&quot;}),
      #&quot;Riordinate colonne4&quot; = Table.ReorderColumns(#&quot;Rimosse colonne4&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Column1.DATE_BAH&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Suddividi colonna in base al delimitatore&quot; = Table.SplitColumn(#&quot;Riordinate colonne4&quot;, &quot;Column1.DATE_BAH&quot;, Splitter.SplitTextByDelimiter(&quot; &quot;, QuoteStyle.Csv), {&quot;Column1.DATE_BAH.1&quot;, &quot;Column1.DATE_BAH.2&quot;}),
      #&quot;Modificato tipo&quot; = Table.TransformColumnTypes(#&quot;Suddividi colonna in base al delimitatore&quot;,{{&quot;Column1.DATE_BAH.1&quot;, type date}, {&quot;Column1.DATE_BAH.2&quot;, type time}}),
      #&quot;Riordinate colonne5&quot; = Table.ReorderColumns(#&quot;Modificato tipo&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Column1.DATE_BAH.1&quot;, &quot;Column1.DATE_BAH.2&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne5&quot; = Table.RemoveColumns(#&quot;Riordinate colonne5&quot;,{&quot;Column1.host_sc_pr&quot;, &quot;Column1.guest_sc_pr&quot;}),
      #&quot;Riordinate colonne6&quot; = Table.ReorderColumns(#&quot;Rimosse colonne5&quot;,{&quot;Column1.Round&quot;, &quot;Column1.comment&quot;, &quot;Column1.DATE_BAH.1&quot;, &quot;Column1.DATE_BAH.2&quot;, &quot;Column1.short_tag&quot;, &quot;Column1.HOST_NAME&quot;, &quot;Sottoposto a merge.1&quot;, &quot;Sottoposto a merge&quot;, &quot;Column1.GUEST_NAME&quot;, &quot;Column1.Pred_gg&quot;, &quot;Column1.Pred_no_gg&quot;, &quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.goalsavg&quot;, &quot;Column1.weather_low&quot;, &quot;Column1.weather_high&quot;, &quot;Column1.weather_code&quot;, &quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Rimosse colonne6&quot; = Table.RemoveColumns(#&quot;Riordinate colonne6&quot;,{&quot;Column1.odds_gg&quot;, &quot;Column1.odds_gg_frac&quot;, &quot;Column1.odds_gg_y_frac&quot;, &quot;Column1.odds_gg_n_frac&quot;}),
      #&quot;Modificato tipo1&quot; = Table.TransformColumnTypes(#&quot;Rimosse colonne6&quot;,{{&quot;Column1.weather_low&quot;, Int64.Type}, {&quot;Column1.weather_high&quot;, Int64.Type}, {&quot;Column1.weather_code&quot;, Int64.Type}}),
      #&quot;Sostituito valore&quot; = Table.ReplaceValue(#&quot;Modificato tipo1&quot;,&quot;.&quot;,&quot;,&quot;,Replacer.ReplaceText,{&quot;Column1.odds_gg_y&quot;, &quot;Column1.odds_gg_n&quot;, &quot;Column1.goalsavg&quot;}),
      #&quot;Modificato tipo2&quot; = Table.TransformColumnTypes(#&quot;Sostituito valore&quot;,{{&quot;Column1.odds_gg_y&quot;, type number}, {&quot;Column1.odds_gg_n&quot;, type number}, {&quot;Column1.goalsavg&quot;, type number}, {&quot;Column1.Pred_gg&quot;, Percentage.Type}, {&quot;Column1.Pred_no_gg&quot;, Percentage.Type}}),
      #&quot;Divisa colonna&quot; = Table.TransformColumns(#&quot;Modificato tipo2&quot;, {{&quot;Column1.Pred_gg&quot;, each _ / 100, Percentage.Type}}),
      #&quot;Divisa colonna1&quot; = Table.TransformColumns(#&quot;Divisa colonna&quot;, {{&quot;Column1.Pred_no_gg&quot;, each _ / 100, Percentage.Type}})
  in
      #&quot;Divisa colonna1&quot; 
  </code></pre>