title: Access: Sum values from multiple and variable columns
body: <p>In <code>table1</code>, I have the field <code>Pianificato</code> and a lot of columns with name <code>Wxx_yyyy</code>.</p>
  
  <p>I need to update <code>Table1.Pianificato</code> as sum of all the W-columns that satisfy a certain criteria.</p>
  
  <p>The criteria that I should apply, is that xx is higher than a certain value.</p>
  
  <p>In this example, xx > 2. So <code>Table1.W01_2018</code> and <code>Table1.W02_2018</code> will not be considered in the sum.</p>
  
  <p>I don't think that this complex request can be satisfied by a Query. So I think the only way is VBA. </p>
  
  <p><a href="https://i.stack.imgur.com/hJfFf.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hJfFf.jpg" alt="enter image description here"></a></p>