Title: mysql_query error when using remote DB
Last modified: August 21, 2016

---

# mysql_query error when using remote DB

 *  Resolved [iHuman](https://wordpress.org/support/users/ihuman/)
 * (@ihuman)
 * [12 years ago](https://wordpress.org/support/topic/mysql_query-error-when-using-remote-db/)
 * I get the following error in the database cleanup section:
    `Call to a member
   function query() on a non-object in /var/www/vhosts/domain.com/httpdocs/wp-content/
   plugins/wp-clean-up/wp_clean_up_admin.php on line 366`
 * This line is:
    `$result = mysql_query($wcu_sql);`
 * I’ve tried replacing it with $wpdb->query but that didn’t work either. My database
   is hosted on an Amazon Web Services RDS server. Any ideas?
 * thanks!
 * [https://wordpress.org/plugins/wp-clean-up/](https://wordpress.org/plugins/wp-clean-up/)

Viewing 1 replies (of 1 total)

 *  Plugin Author [acalbert](https://wordpress.org/support/users/acalbert/)
 * (@acalbert)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/mysql_query-error-when-using-remote-db/#post-4890942)
 * You can try the new version 1.2.2, mysql_query was deprecated.

Viewing 1 replies (of 1 total)

The topic ‘mysql_query error when using remote DB’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-clean-up.svg)
 * [WP Clean Up](https://wordpress.org/plugins/wp-clean-up/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-clean-up/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-clean-up/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-clean-up/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-clean-up/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-clean-up/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [acalbert](https://wordpress.org/support/users/acalbert/)
 * Last activity: [11 years, 9 months ago](https://wordpress.org/support/topic/mysql_query-error-when-using-remote-db/#post-4890942)
 * Status: resolved