title: Fill multiple columns with value from another dataframe
body: <p>I am trying to fill empty columns in one Pandas dataframe with columns from another Pandas dataframe, based on certain conditions.</p>
  <p>First table is <code>audit_records_df</code> and it looks like this:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>id</th>
  <th>audit_type</th>
  <th>audit_date</th>
  <th>maliciousness_level</th>
  <th>suspicious_counts</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>123456</td>
  <td>Unknown</td>
  <td>2/5/21</td>
  <td>NaN</td>
  <td>NaN</td>
  </tr>
  <tr>
  <td>123456</td>
  <td>Cleared</td>
  <td>2/6/21</td>
  <td>NaN</td>
  <td>NaN</td>
  </tr>
  <tr>
  <td>123456</td>
  <td>Terminated</td>
  <td>2/8/21</td>
  <td>NaN</td>
  <td>NaN</td>
  </tr>
  <tr>
  <td>345678</td>
  <td>Terminated</td>
  <td>2/5/21</td>
  <td>NaN</td>
  <td>NaN</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>Second table is <code>spam_profile_most_recent_notes</code>:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>id</th>
  <th>audit_type</th>
  <th>audit_date</th>
  <th>maliciousness_level</th>
  <th>suspicious_counts</th>
  <th>ire_1</th>
  <th>ire_2</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>123456</td>
  <td>Unknown</td>
  <td>2/5/21</td>
  <td>high</td>
  <td>3</td>
  <td>222</td>
  <td>222</td>
  </tr>
  <tr>
  <td>345678</td>
  <td>Terminated</td>
  <td>2/5/21</td>
  <td>high</td>
  <td>6</td>
  <td>222</td>
  <td>222</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p><strong>Note that unlike</strong> <code>audit_records_df</code> <strong>table (where an</strong> <code>id</code> <strong>could have multiple rows), in</strong> <code>spam_profile_most_recent_notes</code> <strong>table each</strong> <code>id</code> <strong>will only have 1 row.</strong></p>
  <p>I am trying to fill columns <code>maliciousness_level</code> and <code>suspicious_counts</code> in <code>audit_records_df</code> table with values from columns of the same name from <code>spam_profile_most_recent_notes</code> table (we need to ignore columns <code>ire_1</code> and <code>ire_2</code>), based on the following criteria:</p>
  <ul>
  <li>For rows in <code>audit_records_df</code> table where <code>id</code> matches <code>id</code> in <code>spam_profile_most_recent_notes</code>, fill the <code>maliciousness_level</code> and <code>suspicious_counts</code> in <code>audit_records_df</code> table with corresponding values from <code>spam_profile_most_recent_notes</code> table in the rows where <code>id</code> matches.</li>
  </ul>
  <p>After the filling, the <code>audit_records_df</code> table should look like this:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>id</th>
  <th>audit_type</th>
  <th>audit_date</th>
  <th>maliciousness_level</th>
  <th>suspicious_counts</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>123456</td>
  <td>Unknown</td>
  <td>2/5/21</td>
  <td>high</td>
  <td>3</td>
  </tr>
  <tr>
  <td>123456</td>
  <td>Cleared</td>
  <td>2/6/21</td>
  <td>high</td>
  <td>3</td>
  </tr>
  <tr>
  <td>123456</td>
  <td>Terminated</td>
  <td>2/8/21</td>
  <td>high</td>
  <td>3</td>
  </tr>
  <tr>
  <td>345678</td>
  <td>Terminated</td>
  <td>2/5/21</td>
  <td>high</td>
  <td>6</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>I've seen some slightly similar questions like this one: <a href="https://stackoverflow.com/questions/46614289/conditionally-fill-column-with-value-from-another-dataframe-based-on-row-match-i">Conditionally fill column with value from another DataFrame based on row match in Pandas</a>. However, all I've seen were regarding filling in value in 1 column, unlike my use case where I have to fill in values for multiple columns.</p>
  <p>Any advice would be greatly appreciated.</p>