0

we have a WooCommerce website and it has a single database. In wp-config.php I setup the connection to the database:

user1
name_of_db
psw_for_db_user

We have an ERP software installed on our office and we bought a software that will synchronize some data between ERP and WooCommerce (orders, prices, stock…).

This software (in the middle between the ERP and WC) needs to connect directly to the database of WordPress. Can I create a new user and password to connect to the database from this software? Is it safe or we will ecounter problems in WordPress/WooCommerce having two different db users making changes in the db?

Thanks!

2

Can I create a new user and password to connect to the database

Yes, this is perfectly fine. Usually applications like WordPress or WooCommerce do not care about what user they are using for the connection - as long as they can read and write data as they need to.

You might even consider it good practice to have different db users for different applications. So if ever your WP got hacked, they would not have the credentials for the other application / database.

Is it safe or we will ecounter problems in WordPress/WooCommerce having two different db users making changes in the db?

This can be problematic. If the other application deletes a product from the Woo db, the product is gone. So if you give another application access to the DB that WordPress is using, you need to be aware that this software could potentially destroy your WP instance.

This is usually where trust comes in. Is that ERP coming from a known vendor that has good reviews, and does their official guide say that it is good to connect directly to the Woo database? Then it should be fine.

1
  • Thank you very much for the info. The software between the ERP and WooCommerce will update only few data in WP db like stock amounts, prices and order statuses and this should not be a problem (I hope so!). Feb 5 at 12:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.