We have a PHP/MySQL site and we need to connect to a Drupal site and update certain tables/fields in its database.
- Does Drupal have any mechanism that allows that?
- If not, how can I connect to the Drupal site/ database and do that? Can Drupal allow a PHP script to listen for connections from our site and after authenticating it, update the local database?
- Is it safe / secure / reliable to do a connect to the MySQL database running on the Drupal site?
This is very doable. Your hosting provider probably gives you some way to talk to the database directly (shell access or phpMyAdmin, for example).
If you want something better than just raw SQL, though, you might consider building a web service. See the drupal services module.