title: How I can return the updated row ID in the given code
body: <p>This code is working fine for updating the row , but I want to <code>RETURN</code> the updated Row ID. Please let me know how I can do that. </p>
  
  <pre><code>static function editProject($arr)
  {
      foreach ($arr as $key =&gt; $value) {
          $$key = $value;
      }
      $db = new DatabaseConnection();
      $dbh = $db-&gt;getDBH();
      $sql = "UPDATE Project SET Job_Name='$JobName',Job_Number='$JobNumber',Location='$Location',
              Project_SupervisorID='$ProjectSupervisorID',Project_ManagerID='$ProjectManagerID',Notes='$Notes',Category='$Category'
              WHERE ID='$ID'";
      $pdo = $dbh-&gt;query($sql);
      $db-&gt;disconnect();
      return $pdo-&gt;rowCount(); // INSTEAD of ROW COUNT RETURN I WANT TO RETURN ID here
   }
  </code></pre>