wp_update_post deletes post meta in CPT

Not sure about the problem with wp_update_post but it is a simple enough SQL query:

global $wpdb;
$query = "UPDATE ".$wpdb->prefix."posts SET post_status="draft" WHERE ID = '".$directory->ID."'";
$wpdb->query($query);

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)