title: How to add a weighted average in my pivot table?
body: <p>I would like to know how to add a weighted average in my pivot table. In fact, I need to do the following calculation: <code>SUM(col1 * col2)/SUM(col2)</code>.</p>
  
  <p>I tried to do it by using the calculated field option but when I enter my formula, I just have the following result as an output: <code>SUM((col1 * col2)/col2)</code> which is equal to <code>SUM(col1)</code>.</p>