Answers.Body: <p>When you go to <strong>Administer menu » Customize Data and Screens » Summary Fields</strong>, the last option is <em>When should these changes be applied?</em>. Your summary fields will be primed at the time selected.  If you want to look at the code, the function is <a href="https://github.com/progressivetech/net.ourpowerbase.sumfields/blob/2646969738016a80f000c5bcedac1b1062a3d42c/sumfields.php#L1298" rel="nofollow noreferrer">sumfields_gen_data</a>.</p>
  
  <p><a href="https://i.sstatic.net/gCSdp.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/gCSdp.png" alt="enter image description here"></a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-03-09T01:21:18.693Z
Answers.LastActivityDate: 2020-03-09T01:21:18.693Z
Answers.UserDisplayName: Jon G - Megaphone Tech
Body: <p>I hope you can help. I am new to CiviCRM and writing a custom Summary Field. </p>
  
  <p>I have written the new field and the trigger, but I am confused about how this will count all of the values for before today. Is there a place in the extension I need to include another query? Is there other magic I am missing? </p>
  
  <p>Thanks,
  Penny </p>
  
Tags: <contacts><summaryfields>
Title: Priming Summary Fields
ThreadText: # Priming Summary Fields
  
  (Asked by: username_0 on 2020-03-08)
  
  I hope you can help. I am new to CiviCRM and writing a custom Summary Field.
  
  I have written the new field and the trigger, but I am confused about how this will count all of the values for before today. Is there a place in the extension I need to include another query? Is there other magic I am missing?
  
  Thanks,
  Penny
  
  **Tags:** contacts, summaryfields
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2020-03-09. Score: 2
  
  When you go to **Administer menu » Customize Data and Screens » Summary Fields**, the last option is *When should these changes be applied?*. Your summary fields will be primed at the time selected. If you want to look at the code, the function is [sumfields\_gen\_data](https://github.com/progressivetech/net.ourpowerbase.sumfields/blob/2646969738016a80f000c5bcedac1b1062a3d42c/sumfields.php#L1298).
  
  [![enter image description here](https://i.sstatic.net/gCSdp.png)](https://i.sstatic.net/gCSdp.png)
  
  
  ---
  
  