diff --git a/addressbook/inc/class.contacts_ldap.inc.php b/addressbook/inc/class.contacts_ldap.inc.php index a6e68e2de4..ec8efb4311 100644 --- a/addressbook/inc/class.contacts_ldap.inc.php +++ b/addressbook/inc/class.contacts_ldap.inc.php @@ -741,7 +741,7 @@ $err = ldap_delete($this->ldap,$entry['dn']); } - $this->db->query("DELETE FROM $this->ext_table WHERE owner=$owner",__LINE__,__FILE__); + $this->db->query("DELETE FROM $this->ext_table WHERE contact_owner=$owner",__LINE__,__FILE__); } return; } diff --git a/addressbook/inc/class.contacts_sql.inc.php b/addressbook/inc/class.contacts_sql.inc.php index da8284b5c5..bc347a8364 100644 --- a/addressbook/inc/class.contacts_sql.inc.php +++ b/addressbook/inc/class.contacts_sql.inc.php @@ -590,7 +590,7 @@ if ($owner) { $this->db->query("DELETE FROM $this->std_table WHERE owner=$owner",__LINE__,__FILE__); - $this->db->query("DELETE FROM $this->ext_table WHERE owner=$owner",__LINE__,__FILE__); + $this->db->query("DELETE FROM $this->ext_table WHERE contact_owner=$owner",__LINE__,__FILE__); } return; }